🔧 AI Nachrichten ChatGPT showing blank screen [Fix](05.09.2026 um 19:55 Uhr)
🔧 AI Nachrichten GenAI Workflows für Social Media Content(02.09.2026 um 14:00 Uhr)
🔧 AI Nachrichten GenAI Workflows für Social Media Content(02.09.2026 um 14:00 Uhr)
🔧 AI Nachrichten ChatGPT showing blank screen [Fix](05.09.2026 um 19:55 Uhr)
🔧 AI Nachrichten GenAI Workflows für Social Media Content(02.09.2026 um 14:00 Uhr)
🔧 AI Nachrichten GenAI Workflows für Social Media Content(02.09.2026 um 14:00 Uhr)

🔧 Programmierung 🕛 kürzlich 4 Min Lesezeit
0

Public vs Private Subnets in AWS Explained for Beginners

↗ Quelle (dev.to)
🗣️ Stimme:
📑 Inhaltsübersicht

When learning AWS networking, one of the most important concepts to understand is the difference between:




  • Public Subnet

  • Private Subnet



At first these terms may sound confusing. But once you understand how internet access works inside a VPC, the concept becomes very simple.



In this article, we will understand:




  • What a subnet is

  • What public and private subnets are

  • How internet access works in AWS

  • What a Load Balancer does

  • How routing works

  • Real-world architecture examples






What is a Subnet?



A subnet is a smaller network created inside a VPC.



When we create a VPC, AWS gives us a large IP address range called a CIDR Block.



Example: 192.168.0.0/16



Instead of using the entire IP block, we divide it into smaller sections called Subnets. This helps organize resources properly and improves security.



We mainly have two types of subnets:




  • Public Subnet

  • Private Subnet






Why Do We Need Different Subnets?



Think of a company office building:




CODE
Office Building
├── Reception Area (Public)
└── Server Room (Private)








  • Reception Area → Anyone can enter (customers, visitors, delivery people) → Similar to Public Subnet


  • Server Room → Only authorized employees can enter → Similar to Private Subnet



This is how AWS works. Not every application component should be exposed to the internet.



For example:




  • Users should access frontend applications

  • Databases should remain private

  • Backend services should stay protected







Understanding Route Tables



A Route Table decides where network traffic should go.



Public Subnet Route Example:




  • Destination: 0.0.0.0/0

  • Target: Internet Gateway



This route makes the subnet Public.







What is a Private Subnet?



A Private Subnet does not allow direct internet access. Resources inside it are hidden from the internet.



Examples:




  • Databases

  • Backend APIs





Why Private Subnets are Important?



Sensitive data should never be exposed publicly.



Examples: MySQL databases, Banking systems, Payment services.



Keeping them private improves security significantly.





Real World Example of Private Subnet



In a banking application bank.com, customers should never directly access:




  • Database servers

  • Account systems

  • Transaction services



So these are placed in Private Subnets.




CODE
Internet User

Website

Backend Application

Database









Private Subnet Routing



Private subnet route tables usually don't contain a Route to internet gateway.



Example: No Route to Internet Gateway



Meaning: Internet access is blocked.



This prevents from direct communication from the internet.






Public vs Private Subnet Comparison

































Feature Public Subnet Private Subnet
Internet Access Yes No
Directly Reachable Yes No
Used For Web Applications, Load Balancers Databases, Backend Applications
Security Level Lower Higher








Complete Real-World AWS Architecture



This is the most common architecture used in real AWS projects. It combines both Public and Private Subnets to create a secure and scalable application.








Conclusion



Public and Private Subnets are fundamental building blocks of secure and scalable AWS architecture.





  • Public Subnets allow resources to be accessed from the internet (like web servers and load balancers).


  • Private Subnets keep sensitive resources safe and hidden from the internet (like databases and backend applications).



By properly using Internet Gateway, Route Tables, and separating your resources into public and private subnets, you can build applications that are both highly available and secure.






Key Takeaways:




  • Always place internet-facing components in Public Subnets.

  • Keep databases and backend logic in Private Subnets.

  • Use Load Balancers in public subnets to distribute traffic efficiently.

  • This 3-Tier Architecture (Web → Application → Database) is one of the most commonly used patterns in real-world AWS projects.



Mastering Public and Private Subnets is a big step toward becoming confident in AWS networking.



In the next articles, we will learn about NAT Gateway (how private subnets can access the internet for updates), Security Groups, and Network ACLs.

Vollständiger Original-Bericht
Ausführliche Details, Code-Beispiele & Hersteller-Stellungnahme auf dev.to.
↗ Original-Artikel auf dev.to lesen
Wie bewertest du diesen Beitrag?
1 Klick Feedback
Teilen mit Netzwerk & Team:

Community-Analysen & Experten-Meinungen 0

Verfasse deine eigene Analyse, teile Workarounds oder diskutiere diesen Vorfall im Blog.
Noch keine Community-Analyse verfasst. Markiere einen Textabschnitt oder klicke oben auf Eigene Analyse verfassen“!
Community Pulse: Relevanz-Einschätzung
1 Klick Experten-Votum
🔴 Akute Relevanz 49%
🟡 In Evaluierung 29%
🟢 Keine Auswirkung 17%
Spannende Innovation 5%
Verwandte Story-Cluster & Quellen (Vektor-KI)
Port 8095 Engine
2 Quellen
GenAI Workflows für Social Media Content
1 Quelle
ChatGPT showing blank screen [Fix]
1 Quelle
Führt Vibe-Coding und AI-Slop zu Windows 11-Problemen (Desktop-Background, Mauszeiger etc.)?
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten Public vs Private Subnets in AWS Explained for Beginners

Thematisch verwandte Begriffe: Public, Private, Subnets, Explained · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...