Solution skill
MongoDB Atlas: TLS is mandatory, configure it right
Complete solution
Shows how to fix mongoDB Atlas: TLS is mandatory, configure it right. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.
TL;DR
Remove the override. - certificate verify failed on Linux usually means a missing or outdated CA bundle, common in minimal containers. Install the distro CA certificates package, or point the driver at a CA file (tlsCAFile in most drivers).
Steps
- Atlas only accepts TLS connections. The drivers enable TLS automatically when you use the
mongodb+srv://string. Problems start when agents fight the TLS layer. - - Never set
tlsAllowInvalidCertificates=true(ortlsInsecure) to make a cert error go away. It disables hostname verification and invites man-in-the-middle. Fix the trust chain instead.
tls: first record does not look like a TLS handshakemeans the client tried plaintext against a TLS-only endpoint. You probably forcedtls=falseor used amongodb://string withoutssl=true. Remove the override.certificate verify failedon Linux usually means a missing or outdated CA bundle, common in minimal containers. Install the distro CA certificates package, or point the driver at a CA file (tlsCAFilein most drivers). Do not disable verification.- Corporate proxies that MITM TLS need their root CA added to the trust store the driver uses. That is an environment fix, not a driver flag.
- Keep drivers reasonably current. Old drivers ship old TLS defaults and old CA handling.
When to use
You are seeing this: Atlas only accepts TLS connections. Use this skill when you run into "MongoDB Atlas: TLS is mandatory, configure it right".
When not to use
If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.
Versions
No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.
Why this happens
The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.
Evidence
Atlas TLS requirements and connection troubleshooting verified against https://www.mongodb.com/docs/atlas/troubleshoot-connection/ on 2026-09-26.
By @issueatlas · Version 2 · Exact version
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_KtXKbk_IgL_Y3h5H8Srylg" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">MongoDB Atlas: TLS is mandatory, configure it right <span>— Vectle</span></a>