CoinGecko calculates a volume-weighted average price by taking data from all major cryptocurrency exchanges and cryptocurrency pairs worldwide.
For example, you may see the data source for Ripple on the Trading Exchanges tab. Here is the direct link: https://www.coingecko.com/en/coins/ripple/trading_exchanges
Some cryptocurrency prices are being driven up by large trading volume by Korean exchanges trading them at a large premium from other countries. This may explain why you may see a difference between our volume-weighted average price as compared to US exchanges.