# Solving the MCP Authentication Headache with Vercel & Better Auth

DevFeed: [Solving the MCP Authentication Headache with Vercel & Better Auth](<https://devfeed.tech/articles/solving-the-mcp-authentication-headache-with-vercel-better-auth-5798.md>)

Original publisher: [Read original article](<https://neon.com/blog/solving-mcp-with-vercel-and-better-auth>)

Author: Ryan Vogel

Published: 2025-05-23T19:29:57Z

Content type: tutorial

Language: en

Sources: [Blog -- Neon Docs](<https://devfeed.tech/sources/blog-neon-docs.md>)

Topics: [MSP MCP](<https://devfeed.tech/topics/msp-mcp.md>)

Tags: [ai-models](<https://devfeed.tech/tags/ai-models.md>), [auth](<https://devfeed.tech/tags/auth.md>), [authentication](<https://devfeed.tech/tags/authentication.md>), [community](<https://devfeed.tech/tags/community.md>), [llms](<https://devfeed.tech/tags/llms.md>), [mcp](<https://devfeed.tech/tags/mcp.md>), [mcp-server](<https://devfeed.tech/tags/mcp-server.md>), [model-context-protocol](<https://devfeed.tech/tags/model-context-protocol.md>), [next-js](<https://devfeed.tech/tags/next-js.md>), [oauth](<https://devfeed.tech/tags/oauth.md>), [tools](<https://devfeed.tech/tags/tools.md>), [vercel](<https://devfeed.tech/tags/vercel.md>)

## AI overview

A tutorial on adding MCP authentication to a Next.js MCP server using Better Auth, Vercel tooling, and OAuth routes.

## Source excerpt

The Problem There have been a lot of different evolutions of external function calling with this age of LLMs. First it was plugins, then it was tool calling, then it now is MCP (which looks like it is here to stay). But throughout all of that there has been one consistent issue,...