Asset Management
Asset Management

Coinbase Index Widget

The Coinbase Index Widget enables publishers, website developers and bloggers to display the performance of Coinbase Index (CBI) in real time. This widget makes it easier to embed and share cryptocurrency data with a dynamic ticker and sparkline that moves with the market: no more out of date screenshots.

The widget makes a request to load the last 24 hours of Coinbase Index values from the Coinbase API. It also connects to the Coinbase API websocket to receive a stream of new CBI values to update the ticker in real time. Finally, when clicked, the widget will link users to the Coinbase Index webpage for more information.

To embed the Coinbase Index Widget in an iframe, use the following snippet:

<iframe scrolling='no' frameborder='false' height='160' width='290' src='https://index-am.coinbase.com/widget/index'></iframe>

To use the Coinbase Index Widget with oEmbed, use the following URL:

https://index-am.coinbase.com/oembed.json?url=https://index-am.coinbase.com/widget/index

Optionally, max height and max width parameters can be added to the above URL like so:

https://index-am.coinbase.com/oembed.json?url=https://index-am.coinbase.com/widget/index&maxwidth=500&maxheight=200