Prices.hour

The prices.hour table provides hourly price data for tokens across multiple blockchains. For details on price calculation methodology, including VWAP calculations and outlier filtering, see the Prices Overview.

Table Structure

Column nameData typeDescription
contract_addressvarbinaryUnique identifier of the token (contract address for ERC20, mint address for Solana, null for native currencies)
blockchainvarcharThe blockchain on which the token exists
symbolvarcharThe identifier of the asset (ticker, cashtag)
pricedoubleThe hourly price of the asset in USD
timestamptimestampThe timestamp for which this price is reported

Usage

This table is useful for intraday analysis and tracking price movements with higher granularity than daily data. It’s suitable for examining price patterns within a day or across multiple days.

Latency and Update Frequency

The prices.hour table is updated hourly based on the upstream dex.trades data pipeline. As a result, prices typically have a latency of approximately 1 hour from real-time.

Example Query

SELECT
    contract_address,
    blockchain,
    symbol,
    price,
    timestamp
FROM prices.hour
WHERE
    blockchain = 'ethereum'
    AND contract_address = 0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2 -- WETH
    AND timestamp >= NOW() - INTERVAL '7' DAY
ORDER BY timestamp asc

Notes

  • Hourly data provides a good balance between granularity and query performance for short to medium-term analyses.
  • As with all price tables, always use contract_address and blockchain for precise token identification.
  • For details on price calculation methodology, including VWAP calculations and outlier filtering, see the Prices Overview.