惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

H
Help Net Security
爱范儿
爱范儿
V
Visual Studio Blog
Last Week in AI
Last Week in AI
阮一峰的网络日志
阮一峰的网络日志
雷峰网
雷峰网
Hugging Face - Blog
Hugging Face - Blog
博客园 - 【当耐特】
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
博客园 - 三生石上(FineUI控件)
博客园 - Franky
博客园 - 叶小钗
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
The Cloudflare Blog
大猫的无限游戏
大猫的无限游戏
人人都是产品经理
人人都是产品经理
M
MIT News - Artificial intelligence
罗磊的独立博客
L
LangChain Blog
Jina AI
Jina AI
IT之家
IT之家
J
Java Code Geeks
Microsoft Azure Blog
Microsoft Azure Blog
博客园_首页

Supabase Blog

AI Agents Know About Supabase. They Don't Always Use It Right. Custom OIDC Providers for Supabase Auth 100,000 GitHub stars Supabase docs over SSH Navigating Regional Network Blocks Supabase Joins the Stripe Projects Developer Preview Log Drains: Now available on Pro Supabase Storage: major performance, security, and reliability updates Supabase incident on February 12, 2026 Hydra joins Supabase X / Twitter OAuth 2.0 is now available for Supabase Auth BKND joins Supabase Supabase is now an official Claude connector Supabase PrivateLink is now available Introducing: Postgres Best Practices When to use Read Replicas vs. bigger compute Introducing TRAE SOLO integration with Supabase Supabase Security Retro: 2025 Sync Stripe Data to Your Supabase Database in One Click Building ChatGPT Apps with Supabase Edge Functions and mcp-use Own Your Observability: Supabase Metrics API Introducing iceberg-js: A JavaScript Client for Apache Iceberg Introducing Supabase for Platforms Adding Async Streaming to Postgres Foreign Data Wrappers Build "Sign in with Your App" using Supabase Auth Introducing Seven New Email Templates for Supabase Auth The new Supabase power for Kiro Introducing Supabase ETL Introducing Analytics Buckets Introducing Vector Buckets
Data API Routes to Nearest Read Replica
José Ledesma · 2025-04-04 · via Supabase Blog

Data API Routes to Nearest Read Replica

Today we’re releasing Data API requests routing to the nearest Read Replica by extending our API load balancer to handle geo-routing.

It’s an impactful improvement that will minimize request latency for your globally distributed applications. It’s available by default when using a load balancer endpoint.

Geo-routing automatically directs your Data API requests to the geographically closest read replica of your database, reducing latency and improving response times for your users around the world.

Previously, if you had read replicas in Frankfurt, Singapore, and Virginia, a user located in Europe may experience dramatically different latencies because they could be making requests to any of the replicas.

Our new geo-routing automatically connects users to the nearest read replica so the same user would only make requests to the read replica in the Frankfurt region.

Our geo-routing system uses geospatial algorithms to determine the optimal read replica for each request:

  1. Each incoming API request includes geolocation data from the network edge (specifically the cf.colo property, which provides the IATA airport code of the datacenter that received the request).
  2. We maintain a coordinate mapping system that associates each region where read replicas can be deployed with precise geospatial coordinates.
  3. When a request arrives, we calculate the distance between the network edge and each available read replica using the Haversine formula (which determines the great-circle distance between two points on a sphere using their longitudes and latitudes).
  4. The system automatically routes the request to the geographically closest read replica, minimizing network latency without requiring any configuration on your part.
  5. In cases where multiple databases exist in the same region we implement a round-robin strategy to ensure balanced load distribution.

The entire process is completely seamless to your application and users, requiring no changes to your code or configuration besides updating your project URL (<project_ref>-all.supabase.co) today.

To get the most from geo-routing, deploy read replicas in regions where your users are concentrated. The more strategically you place your read replicas, the more your users will benefit from reduced latency and improved response times.

As an initial release, geo-routing is available with the following limitations:

  • Currently limited to read-only Data API (PostgREST) requests

If you're already using our API load balancer there's nothing you need to do; geo-routing is automatically applied to your Data API requests.

Otherwise, you can enable this feature by ensuring your project is using the API load balancer endpoint (<project_ref>-all.supabase.co)

We're actively working on expanding geo-routing support to other Supabase products, such as Auth, Storage, and Realtime. Stay tuned for updates.

As always, we welcome your feedback, let us know what you think!