'Unable to connect to PostgreSQL databese on Amazon RDS from pgAdmin4: internal server error: port 5432 failed: timeout expired

I'm getting this error while performing the steps from the video: https://www.youtube.com/watch?v=XDMgXZUfa10&t=897s

The error:

enter image description here



Solution 1:[1]

try to configure security group. EC2 -> Security Groups -> choose your security group -> edit -> check source (0.0.0.0/0 allows everyone to connect to the database)

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Stanislav Afanasyev