SSL Certificate Validation in Insomnia | Generated by AI

Home PDF

To fix the “SSL peer certificate or SSH remote key was not OK” error in Insomnia, this error typically occurs when Insomnia cannot verify the SSL certificate of the server you’re trying to connect to. Below are step-by-step solutions to resolve this issue:

1. Disable SSL Certificate Validation (For Local Development Only)

If you’re working with a local development server that uses a self-signed or invalid SSL certificate, you can disable certificate validation in Insomnia:

Important: This option bypasses security checks and should only be used for testing or local development. Do not use it for production environments, as it makes your connection vulnerable.


2. Verify the Server’s SSL Certificate

The error might indicate an issue with the server’s SSL certificate (e.g., expired, self-signed, or hostname mismatch). To check:


3. Import a Client Certificate (If Required)

If the server requires a client certificate for authentication, you’ll need to configure it in Insomnia:


4. Update Insomnia

SSL-related issues might be due to a bug in an older version of Insomnia. To ensure you’re on the latest version:


5. Test with Curl

If the above steps don’t resolve the issue, test the request outside of Insomnia to isolate the problem:


Summary

Start by disabling SSL validation if it’s a local server, then verify the server’s certificate or configure a client certificate if needed. Ensure Insomnia is up to date, and use curl to troubleshoot further if necessary. These steps should resolve most cases of the “SSL peer certificate or SSH remote key was not OK” error.

If the issue persists, it may be due to a server-side misconfiguration or a rare bug in Insomnia. Let me know if you need more assistance!


Back 2025.03.01 Donate