Introduction
Ever wanted to use advanced AI models in Cursor without paying for a Pro subscription? You're in luck! OpenRouter makes it super easy to connect powerful AI models like GPT-4o, Claude 3.5 Sonnet, and more—without breaking the bank. In this guide, I'll show you exactly how to set it up in just a few steps.
Why OpenRouter?
Think of OpenRouter as your all-access pass to some of the best AI models out there. Instead of being locked into one provider, you get to pick and choose from a variety of options, including:
- Claude 3.5 Sonnet – A smart, fast AI from Anthropic.
- GPT-4o – OpenAI’s latest powerhouse for deep reasoning and creativity.
- Gemini 1.5 Pro – Google’s top-tier AI for versatile tasks.
- Deepseek Coder V2 – A specialized AI assistant for coding.
The best part? You can seamlessly integrate these models into Cursor without needing a Pro plan. Let’s set it up!
How to Use Openrouter in Cursor
1. Get Your OpenRouter API Key
- Head over to OpenRouter and create an account.
- Navigate to your settings and generate an API key.
2. Configure Cursor to Use OpenRouter
- Open Cursor and go to Cursor Settings (typically using
Ctrl+Shift+J
orCmd+Shift+J
).
- Go to the Models tab.
- In the Override OpenAI Base URL field, enter:
https://openrouter.ai/api/v1
- Paste your OpenRouter API key into the OpenAI API Key field.
- Hit Save, and restart Cursor if necessary.
- Choose one of OpenRouter’s supported models, like
gpt-4o
orclaude-3.5-sonnet
or whatever models you prefer.
Now you are good to go! 🎉
Press Command + L
and Try it out with a prompt and see the magic happen!
Final Thoughts
And that’s it! With OpenRouter, you can access top-tier AI models tailored to your needs—whether for coding, brainstorming, or AI-assisted development. Stay updated with Cursor and OpenRouter’s docs as features evolve, and experiment to find the best fit for your workflow. Give it a try, and if you run into any issues, check out the OpenRouter Docs or tweak Cursor’s settings. 🚀