---
title: "How to Set up Amazon RDS PostgreSQL Database"
description: "Learn how to quickly set up a simple Amazon RDS PostgreSQL with this step-by-step tutorial."
canonical: "https://adamtheautomator.com/rds-postgres/"
---

# How to Set up Amazon RDS PostgreSQL Database

> Learn how to quickly set up a simple Amazon RDS PostgreSQL with this step-by-step tutorial.

Source: https://adamtheautomator.com/rds-postgres/

---

ATA Learning

Tap to hide

[

ATA Learning

](/)

*   [Home](/)
*   [Tutorials](/tutorials/)
*   [Instructors](/author/)
*   [Advertising](/advertising/)
*   [Recommended Resources](/resources/)
*   [About Adam](/about-adam/)

Search for:  

*   [](https://twitter.com/adbertram)
*   [](https://github.com/Adam-the-Automator)
*   [](https://www.linkedin.com/company/adam-the-automator-llc)
*   [](/feed/)

![How to Set up Amazon RDS PostgreSQL Database](https://adamtheautomator.com/wp-content/uploads/2021/03/How-to-Set-up-a-PostgreSQL-Database-on-Amazon-RDS.jpg)

# How to Set up Amazon RDS PostgreSQL Database

[![](https://secure.gravatar.com/avatar/2beb65fca997135120ed98dc6a2e57dcdf1a7d7d2f5ff687b5d91dc7ccd7a6b5?s=192&d=mm&r=g)Sagar](https://adamtheautomator.com/author/shanky-mendiratta/)11 March 20214 min. read

Categories: [IT Ops](/category/it-ops/)

Tags:[AWS](/tag/aws/)

Table of Contents

*   [Prerequisites](#prerequisites)
*   [Creating the RDS PostgreSQL Instance](#h-creating-the-rds-postgresql-instance)
*   [Connecting to the RDS Instance](#h-connecting-to-the-rds-instance)
*   [Creating a Database](#h-creating-a-database)
*   [Conclusion](#h-conclusion)

If you need to create and connect to an Amazon RDS Postgres [SQL](https://adamtheautomator.com/connect-to-sql-server-from-linux/) database, you’ve come to the right place. Creating your first [_Amazon Relational Database Service (RDS)_](https://aws.amazon.com/rds/) database might be a challenge but in this tutorial, you’re going to learn how to make it happen, step-by-step.

Related:[Connect to SQL Server from Linux](https://adamtheautomator.com/connect-to-sql-server-from-linux/)

## P**rerequisites**

This post will be a step-by-step tutorial. If you’d like to follow along, please be sure you have the following in place:

*   An [_AWS account_](https://repost.aws/knowledge-center/create-and-activate-aws-account)
*   A client to connect to the PostgreSQL database. This tutorial will be using the _[pgAdmin utility](https://www.pgadmin.org/download/)._

> _You may incur a small charge for creating an RDS instance on Amazon Managed Web Service. When you’re done, be sure to [remove the RDS instance](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_DeleteInstance.html)._

## **Creating the RDS PostgreSQL Instance**

Before you can use a PostgreSQL RDS instance, you must create it. This tutorial will use the _[AWS Management Console](https://aws.amazon.com/console/)._

1.  Sign into the AWS Management Console with your AWS account.

2\. At the top of the page, you should see a search box where you can search various amazon web services. In the search box, type “RDS” and select the RDS service that comes up. This will bring you to the Amazon RDS page.

![Navigating to the RDS management page](https://devopsdatacenter.files.wordpress.com/2021/02/image-46.png?w=1024)

Navigating to the RDS management page

3\. On the Amazon RDS page, click on **Databases** and then click on the **Create database** button on the right.

![RDS database pages](https://devopsdatacenter.files.wordpress.com/2021/02/image-47.png?w=1024)

RDS database pages

4\. Next, choose **Standard create**. Creating the instance with the **Standard create** method allows you to customize the instance more than using the **Easy create** method.

5\. Select **PostgreSQL** as the database engine and the **Version**. This tutorial will use the latest version at the time of writing which is version **12.5-R1** but you can choose many versions of PostgreSQL here.

6\. Choose the **Free tier** for the **Template** since you’re just learning at this time.

![Defining standard PostgreSQL database options](https://devopsdatacenter.files.wordpress.com/2021/02/image-51.png?w=725)

Defining standard PostgreSQL database options

7\. Scroll down a bit and now provide:

*   The database name as the **DB instance identifier**
*   A username for the **Master username**
*   A password for the **Master password**Once you create the database, you can add other database users.

Once you create the database, you can add other database users.

![Providing the RDS instance name, instance type and user information](https://devopsdatacenter.files.wordpress.com/2021/02/image-52.png?w=682)

Providing the RDS instance name, instance type and user information

8\. You can choose a number of instance classes in the **DB instance class** depending on the performance you need from the instance. Since this tutorial is just a demonstration, choose any free instance such as **db.t2.micro**.

> _Find all available instance types [here](https://aws.amazon.com/rds/instance-types/) with various instance size._

Although configurable, leave the **Storage type**, **Allocated storage,** and **Maximum storage threshold** fields default.

![Defining RDS instance storage options You can find more information about storage options here.](https://devopsdatacenter.files.wordpress.com/2021/02/image-53.png?w=575)

Defining RDS instance storage options _You can find more information about storage options [here](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Storage.html)._

> _You can find more information about storage options_ [here](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Storage.html)_._

10\. Since this is just a test, specify the **Default VPC** for the **Virtual private cloud (VPC)**. This setting will ensure the RDS instance is available within a specific VPC.

11\. Set the **Subnet group** to **default** which will use the default subnet associated with the VPC.

12\. Ensure the **Database port** is set to **5432** which is the default for PostgreSQL.

![Setting network connectivity to the PostgreSQL RDS instance](https://devopsdatacenter.files.wordpress.com/2021/02/image-55.png?w=657)

Setting network connectivity to the PostgreSQL RDS instance

13\. Ensure **Password authentication** is set for **Database authentication**. This scenario allows you to authenticate to the database using users defined in the database and is the simplest method.

![Creating the RDS database instance](https://devopsdatacenter.files.wordpress.com/2021/02/image-57.png?w=710)

Creating the RDS database instance

14\. Finally, click on **Create database** to begin creating the RDS PostgreSQL instance.

AWS will take a few minutes to create your RDS instance. However, once it does, you will see your instance show up with a **Status** of **Available** shown below.

![Successful PostgreSQL RDS instance](https://devopsdatacenter.files.wordpress.com/2021/02/image-59.png?w=1024)

Successful PostgreSQL RDS instance

## Connecting to the RDS Instance

Once you’ve created the RDS instance, it’s time to connect to it. This tutorial will use a free tool call _pgAdmin,_ but you can find [_many other PostgreSQL clients_](https://wiki.postgresql.org/wiki/PostgreSQL_Clients) that will fit your needs.

Assuming you’ve already installed pgAdmin:

1.  Open pgAdmin4 and right-click on the **Servers** node, click **Create** —> **Server**. This will bring up a new server connection window.

![pgAdmin4](https://devopsdatacenter.files.wordpress.com/2021/02/image-63.png?w=534)

pgAdmin4

2\. On the **General** Tab, provide a **Name** for the server. This tutorial will use _myrds_.

Ensure that the:

*   **Host name/address** is _<DB instance name>.<region identifier>.rds.amazon.com_
*   **Port** is 5432 (the same as defined while creating the instance)
*   **Maintenance database** is set to _postgres_. This is the default database that every PostgreSQL RDS instance should have.
*   **Username** is _postgres,_ and the **Password** is the Master password provided while creating the instance

![Create Server](https://devopsdatacenter.files.wordpress.com/2021/02/image-64.png?w=520)

Create Server

![Username and Password](https://devopsdatacenter.files.wordpress.com/2021/02/image-65.png?w=530)

Username and Password

4\. Click **Save** to save the server connection.

pgAdmin should now automatically connect to the PostgreSQL RDS instance, and you will see it displayed under the **Servers** node as shown below.

![Servers node](https://devopsdatacenter.files.wordpress.com/2021/02/image-66.png?w=226)

**Servers** node

> _If your client doesn’t automatically connect to the instance, be sure to confirm the [security group for the VPC](https://docs.aws.amazon.com/vpc/latest/userguide/VPC_SecurityGroups.html) you associated the RDS instance to allows inbound rules on port 5432. Ensure that all ip addresses you intend to connect from are in here. Also make sure your RDS supports publicly accessibility._

## Creating a Database

So you’re now connected to the Postgresql database instance. It’s time to create a database!

To do that with pgAdmin:

1.  Inside of the _myrds_ instance, right-click on **Databases.**
2.  Click on **Create** —> **Database** to open the database creation window.
3.  Provide a database name and click **Save**.

![Providing a Database Name](https://devopsdatacenter.files.wordpress.com/2021/02/image-67.png?w=1024)

Providing a Database Name

If you look under the _myrds_ instance now, you’ll see your new read only database show up as shown below.

![Read Only Database](https://devopsdatacenter.files.wordpress.com/2021/02/image-69.png?w=313)

Read Only Database

Now that you have created a database, you can connect to the database and use it however you need to.

## Conclusion

You should now have a simple PostgreSQL RDS instance running in AWS. This tutorial wasn’t meant to cover any in-depth scenarios but more of a simple guide to get you started.

Your PostgreSQL database should now be ready to begin helping you manage your organization’s data.

Share this article

[Share on X](https://twitter.com/intent/tweet?url=https%3A%2F%2Fadamtheautomator.com%2Frds-postgres%2F&text=How%20to%20Set%20up%20Amazon%20RDS%20PostgreSQL%20Database)[Share on Facebook](https://www.facebook.com/sharer/sharer.php?u=https%3A%2F%2Fadamtheautomator.com%2Frds-postgres%2F)[Share on LinkedIn](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fadamtheautomator.com%2Frds-postgres%2F)

## Related Posts

![](https://adamtheautomator.com/wp-content/uploads/2022/05/HMaster-Your-Data-with-AWS-Quicksight.jpg)

### [Make Data-Driven Decisions with AWS QuickSight Analytics](/aws-quicksight/)

Struggling to make sense of your data? Discover how AWS QuickSight transforms data into actionable insights for smarter decision-making.

![](https://adamtheautomator.com/wp-content/uploads/2023/11/aws-network-access-analyzer-2.jpg)

### [Getting Started with AWS Network Access Analyzer](/aws-network-access-analyzer/)

Unlock the power of AWS Network Access Analyzer. Master network security with step-by-step guidance in this tutorial today!

![](https://adamtheautomator.com/wp-content/uploads/2023/11/ngrok-remote.jpg)

### [Hosting an Ngrok Remote Web App on AWS](/ngrok-remote/)

Learn how to run the Ngrok remote web application on AWS with the FastAPI Python endpoint in Linux through this ATA Learning tutorial!

## Categories

*   [IT Ops](/category/it-ops/)
*   [Cloud](/category/cloud/)
*   [DevOps](/category/devops/)
*   [Home Ops](/category/home-ops/)
*   [Information Security](/category/infosec/)
*   [Software Development](/category/software-development/)

## Site

*   [Home](/)
*   [Tutorials](/tutorials/)
*   [Instructors](/author/)
*   [Advertising](/advertising/)
*   [Recommended Resources](/resources/)
*   [About Adam](/about-adam/)

Copyright 2026© ATA Learning | [Privacy Policy](/privacy/)
