Skip to main content
In this lesson you’ll learn how to deploy a managed PostgreSQL instance using Amazon RDS. RDS removes the need to provision and operate the underlying database server by handling instance provisioning, storage management, automated backups, and other operational tasks.

1. Create Database (Standard vs Easy)

Open the AWS Management Console, search for RDS, and choose Create database. You can pick:
  • Easy (Simple) create — applies opinionated defaults and speeds up creation.
  • Standard create — exposes all configuration options for full control.
For this walkthrough we use Standard create so you can see the available configuration settings.
A screenshot of the AWS RDS "Create database" console showing the database creation method (Standard vs Easy) and engine options. The engine tiles visible include Aurora (MySQL/PostgreSQL compatible), MySQL, MariaDB, PostgreSQL and Oracle.

2. Engine selection and version

Select the database engine you want — choose PostgreSQL for a Postgres instance. Then select the engine version; the default is suitable in most cases unless you need a specific release for compatibility or features.

3. Templates and intended use

RDS offers templates that preconfigure many settings: Select the template that matches your workload — we used Dev/Test for this lesson.

4. Instance configuration (compute)

RDS instances run on instance classes that resemble EC2 types. Pick an instance class that matches your CPU, memory, and network requirements — the console shows vCPU, RAM, and network throughput for each option.
A screenshot of a cloud console dropdown showing database instance classes (e.g., db.m6i.large, db.m6i.xlarge) with their vCPU counts, RAM sizes and network Mbps values. It appears to be an AWS RDS instance type selection panel.

5. Storage

Choose a storage type and the initial size. You can enable storage autoscaling so RDS grows storage as required up to a maximum you define. Storage options (General Purpose SSD, Provisioned IOPS, etc.) vary by cost and performance.
A cloud database storage settings panel (likely AWS RDS) showing "Provisioned IOPS SSD (io1)" with 100 GiB allocated storage, 3000 provisioned IOPS, and storage autoscaling enabled with a 1000 GiB max threshold.
Tip: For workloads with unpredictable growth, enable storage autoscaling and set a sensible maximum to avoid unexpected costs.

6. Connectivity, networking, and optional compute helper

Decide whether to provision an associated compute resource for quick connectivity tests (optional). Choose the VPC and subnets where the DB instance should run — you can use the default VPC or supply a custom network.
A screenshot of an AWS RDS setup page showing compute and network settings with "Don't connect to an EC2 compute resource" and "IPv4" selected. It also displays the Virtual Private Cloud (Default VPC), DB subnet group, and Public access options.
  • Set Public access to No for production (keeps the instance in private subnets). Set to Yes only for temporary testing and ensure strong security rules.
  • Choose a DB subnet group and optionally specify an Availability Zone or leave it as No preference for AWS to pick.

7. Security groups and public access

Create or reuse a security group to control inbound traffic. For local testing, add a rule to allow your client IP on the PostgreSQL port (5432 by default). For production, restrict access to known application subnets or a bastion host.

8. Additional configuration

Under Additional configuration you can:
  • Change the default port (5432).
  • Select authentication methods (password, IAM authentication).
  • Enable enhanced monitoring, performance insights, backups, encryption, and set backup retention windows.
RDS automated backups and point-in-time recovery simplify restores. When ready, click Create database. Provisioning typically takes several minutes while AWS provisions compute, storage, and networking.

9. Instance available — find connectivity details

After the instance status changes to Available, open the DB instance details. Note the Endpoint (host) and Port — you’ll use these, together with the master username and password, to connect from a client.
A screenshot of the Amazon RDS console showing a PostgreSQL DB instance summary (my-first-db) with CPU/status info. The page displays connectivity and security details including endpoint, port, VPC/subnets, and security group.
Example connection using psql:
  • psql -h <your-rds-endpoint> -U postgres -p 5432 -d postgres
Replace <your-rds-endpoint> with the value shown in the console.

10. Connect using pgAdmin

You can connect with GUI tools such as pgAdmin. Create a new server entry and supply:
  • Host: the RDS endpoint (paste from the console)
  • Port: 5432 (or your custom port)
  • Maintenance DB: typically postgres
  • Username: the master username (e.g., postgres)
  • Password: the password you set
A screenshot of the pgAdmin "Create - Server" dialog on the Connection tab, showing an Amazon RDS host endpoint, port 5432, maintenance database and username set to "postgres," and an empty password field. The pgAdmin dashboard with welcome/configure tiles is visible in the background and Cancel/Reset/Save buttons appear at the bottom.
After you save, pgAdmin will show the server and default database. You can create new databases, schemas, tables, and run queries as usual.
A screenshot of the pgAdmin database dashboard with the server/database tree on the left and the "my_app" database selected. The right side shows metrics panels (sessions, transactions/sec, tuples in/out, block I/O) and a server activity table at the bottom.
Do not use the master account credentials for application connections. Create an application-specific database user with the minimum required privileges. For production, use IAM authentication or a secrets manager such as AWS Secrets Manager to store and rotate credentials securely.

11. Modify or delete the instance

  • To change instance settings later, choose Modify in the RDS console to update instance class, storage, backup windows, maintenance windows, and more.
  • To remove the instance, choose Delete. The console will prompt whether to create a final snapshot and whether to retain automated backups — for production systems, create and retain snapshots or export data before deletion.
Screenshot of the Amazon RDS console for a database named "my-first-db." It shows the instance summary (CPU, status "Available", PostgreSQL engine) and the Connectivity & security section with endpoint, port and VPC/subnet details.
If you enable public access, ensure your security group only allows trusted IP addresses on the database port. Exposing a database to the public internet without strict controls increases the risk of unauthorized access.
If you choose Delete, confirm the deletion checkbox(s) and acknowledge the prompt to remove the instance and any retained snapshots (depending on your choices).
A confirmation dialog for deleting the "my-first-db" database instance with checkboxes to create a final snapshot, retain automated backups, and an acknowledgment. There’s an input field partially filled to confirm deletion and Cancel/Delete buttons at the bottom.
That concludes this lesson on deploying and connecting to a PostgreSQL instance on Amazon RDS.

References

Watch Video

Practice Lab