Urgent.News

What's breaking now, across hundreds of outlets.

Tech

401 Unauthorized: It's Almost Never the Model — It's Your Key

The error looks blunt: 401 Unauthorized. Most people read it as "I'm locked out" and start panicking, reinstalling, or blaming the model. In practice a 401 is the simplest error of the lot: the service looked at your key and said "I don't know you". The model never even saw your message. The four usual causes 1. The key is copied wrong. A missing character, a trailing space, or an old key left in…

The error message "401 Unauthorized" can be a frustrating experience for users. Many assume it means the model is inaccessible, leading them to panic, reinstall, or blame the model itself. However, the true culprit is often much simpler: the user's key.

There are four common reasons for a 401 Unauthorized error: a mistyped key, an expired or revoked key, an empty balance, or a mismatch between the address and key. In most cases, it's the user's key that's at fault. A single misplaced character, an extra space, or an old key left in settings can all trigger this error.

To troubleshoot, follow this simple checklist: first, ensure the base URL is correct. Next, paste the key directly from where it was issued, checking for any spaces at the beginning or end. Then, verify the model name matches what the service expects. Finally, check the balance by logging in. If the balance is zero, that's your answer.

Unlike other errors, a 401 means the service has no idea who you are. A 403 means you're recognized but not authorized to access certain features. A 429 indicates the service is overwhelmed and requests should be spaced out. By understanding the difference between these errors, users can save valuable time and effort.

Often, what appears to be an "API is down" situation is actually a dead key or empty balance that was picked up days earlier. Service providers should make these errors clear, so users can diagnose and resolve the issue quickly. Next time a 401 shows up, the first step should always be to check the key.

Rewritten by urgent.news; may contain errors — check the original.

Source: dev.to

Read the original at dev.to →

Report a problem with this story

More in Tech

I turned websites into snow globes. Shake your phone to make it snow.

Open this page on your phone and give it a shake. The snow swirls up, drifts back down as if through water, and settles on the headings and buttons. Tilt the phone and the snow slides to the side.

  • Developer František created "Snow Globe" for websites
  • Snow Globe uses phone sensors and motion events
  • Shaking phone triggers snow effect on websites

The useful part of an agent is the decision boundary

I wrote this as part of the Kiroween 2026 hackathon, where Wraith Kit is my Skeleton Crew entry. TODO Afterlife runs as a hosted demo; no live LLM provider or AWS deployment is claimed.

  • Wraith Kit framework for small event agents with two applications
  • "Todo Afterlife" identifies unclear code comments, proposes actions
  • "Notice Ghoul" scans notice pages for dates, compiles digests

VPS Price Comparison From Budget to Premium

RackVector Linux VPS starts from $1.36 per month. Windows VPS and dedicated CPU VDS start from $5.53 per month. Compare starting prices across 13 providers, from small Linux VPS plans to Windows, storage, managed hosting, and full cloud instances. Prices checked November 30, 2026.

  • RackVector Linux VPS starts at $1.36/month with 2GB RAM and 25GB NVMe SSD storage
  • InterServer Linux VPS begins at $3/month, offering 2GB CPU, 2GB RAM, and 40GB SSD storage
  • Contabo Cloud VPS starts at €4.40/month with 4 vCPUs, 8GB RAM, and 100GB SSD storage

5 things to fix before your Lovable or Bolt app gets real users

By Shubham Maurya , co-founder of BuildKodiq · 2026-11-30 Before real users sign up, fix five things in an app you built with Lovable, Bolt.new, Replit, v0 or Cursor. Turn on row-level security for every table. Keep secret keys out of the browser. Update payments from Stripe webhooks, not from the success page.

  • Implement row-level security policies to control user access to data
  • Remove secret keys from browser and move to server-side functions
  • Use Stripe webhooks for secure payment processing and event verification

More from Sunday, 29 November 2026 →