A CORS Anywhere proxy using the Hono framework, deployed on Cloudflare Workers.
- Proxy requests to bypass CORS restrictions
- Handles URLs passed directly in the path (with query string support)
- Supports both HTTP and HTTPS
- SSRF protection — blocks private/internal IP ranges and cloud metadata endpoints
- Proper URL parsing via
URLconstructor - Shows usage instructions when accessed without a URL
-
Clone the repository:
git clone https://github.com/7a6163/cors-proxy cd cors-proxy -
Install dependencies:
npm install
-
Development:
npm run dev
-
Deploy to Cloudflare Workers:
npm run deploy
Once deployed, pass the target URL directly in the path.
https://your-worker.workers.dev/http://example.com/— Proxies with CORS headershttps://your-worker.workers.dev/example.com— Defaults to HTTPShttps://your-worker.workers.dev/example.com:8080/path— Custom porthttps://your-worker.workers.dev/example.com/api?key=123— Query strings preservedhttps://your-worker.workers.dev/— Shows usage text
This project is licensed under the MIT License.