<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Alex Qu</title>
    <description>The latest articles on DEV Community by Alex Qu (@alex_qu_5a79e160e51d453ea).</description>
    <link>https://dev.to/alex_qu_5a79e160e51d453ea</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3544560%2Ff267f9df-fe32-460d-9e11-532a0ddecff7.png</url>
      <title>DEV Community: Alex Qu</title>
      <link>https://dev.to/alex_qu_5a79e160e51d453ea</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/alex_qu_5a79e160e51d453ea"/>
    <language>en</language>
    <item>
      <title>Understanding The 3-tier Web Application Architecture on AWS and Building One in 5 minutes</title>
      <dc:creator>Alex Qu</dc:creator>
      <pubDate>Wed, 15 Oct 2025 07:42:13 +0000</pubDate>
      <link>https://dev.to/alex_qu_5a79e160e51d453ea/understanding-the-3-tier-web-application-architecture-on-aws-and-building-one-in-5-minutes-51b0</link>
      <guid>https://dev.to/alex_qu_5a79e160e51d453ea/understanding-the-3-tier-web-application-architecture-on-aws-and-building-one-in-5-minutes-51b0</guid>
      <description>&lt;h2&gt;
  
  
  Overview
&lt;/h2&gt;

&lt;p&gt;In this article, we’ll explore the classic &lt;strong&gt;3-tier web application architecture&lt;/strong&gt;: what it is, why it remains relevant despite newer approaches like serverless and containers, when it makes the most sense to use, and who is using it today. Finally, we’ll show you how to launch your own 3-tier web app in just &lt;strong&gt;5 minutes&lt;/strong&gt; using an AI agent we’ve built. Try it &lt;a href="https://skylineopsai.com/AWS-Backend-agent" rel="noopener noreferrer"&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is the 3-tier architecture?
&lt;/h2&gt;

&lt;p&gt;A “3-tier web application” is a classic way of structuring applications so that each major function has its own dedicated layer:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Presentation Tier&lt;/strong&gt; – where users interact with the app.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Application Tier&lt;/strong&gt; – where business logic is executed.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Database Tier&lt;/strong&gt; – where data is kept safe.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This model has been around for decades because it’s &lt;strong&gt;simple, scalable, and reliable&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why does it matter?
&lt;/h2&gt;

&lt;p&gt;The 3-tier design separates responsibilities into clear layers, which makes applications:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;More secure&lt;/strong&gt; – databases aren’t directly exposed to the internet.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Scalable&lt;/strong&gt; – each tier can scale independently based on demand.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Maintainable&lt;/strong&gt; – one layer can be updated without breaking the others.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Resilient&lt;/strong&gt; – load balancers and multiple instances help withstand failures.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  When should you use it?
&lt;/h2&gt;

&lt;p&gt;The 3-tier model is a great fit for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Business applications&lt;/strong&gt; (CRMs, ERPs).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;E-commerce websites&lt;/strong&gt; where both traffic spikes and data integrity are critical.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Enterprise internal tools&lt;/strong&gt; that need reliability and structured separation.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Education &amp;amp; training projects&lt;/strong&gt; where learners want to understand web hosting fundamentals.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Who uses it today?
&lt;/h2&gt;

&lt;p&gt;Despite the rise of serverless and container-based models, many real-world systems still rely on 3-tier architecture, sometimes enhanced with modern tooling:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Banks &amp;amp; financial institutions&lt;/strong&gt; use it for secure transaction systems.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Healthcare providers&lt;/strong&gt; run patient record systems this way.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Large enterprises&lt;/strong&gt; (retail, airlines, universities) still host internal portals on it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;E-commerce platforms&lt;/strong&gt; often start with a 3-tier setup before evolving into microservices.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Chances are, if you’ve logged into a university portal, used a government service website, or shopped on an older e-commerce platform, you’ve interacted with a 3-tier application.&lt;/p&gt;

&lt;h2&gt;
  
  
  Is 3-tier architecture outdated?
&lt;/h2&gt;

&lt;p&gt;In recent years, many companies have embraced &lt;strong&gt;serverless architectures&lt;/strong&gt; (AWS API Gateway + Lambda + DynamoDB) or &lt;strong&gt;containerized solutions&lt;/strong&gt; (ECS, EKS, Fargate, Kubernetes). These can scale faster, reduce management overhead, and cut costs for specific workloads.&lt;/p&gt;

&lt;p&gt;But the 3-tier model is far from obsolete:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Many &lt;strong&gt;legacy systems&lt;/strong&gt; are built on it.&lt;/li&gt;
&lt;li&gt;New projects that need &lt;strong&gt;control, predictability, and compatibility with existing code&lt;/strong&gt; still adopt it.&lt;/li&gt;
&lt;li&gt;Its simplicity makes it easier to teach, learn, and prototype with.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Advantages of 3-tier today
&lt;/h2&gt;

&lt;p&gt;Even in 2025, 3-tier has clear benefits:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Simplicity:&lt;/strong&gt; easy for small teams to understand and implement.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Compatibility:&lt;/strong&gt; works with most languages, frameworks, and legacy code.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Control:&lt;/strong&gt; fine-tune performance and configuration per tier.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Predictability:&lt;/strong&gt; decades of proven patterns mean fewer surprises.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  How to create a 3-tier web application in AWS?
&lt;/h2&gt;

&lt;p&gt;In AWS, the 3-tier architecture can be recreated using &lt;strong&gt;cloud-native services&lt;/strong&gt; that are secure, cost-efficient, and straightforward even for beginners. The application is divided into three layers, each with its own purpose:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Presentation Tier – AWS Application Load Balancer (ALB)&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;Acts as the &lt;strong&gt;entry point&lt;/strong&gt; of your application.&lt;/li&gt;
&lt;li&gt;Deployed in &lt;strong&gt;public subnets&lt;/strong&gt; to receive traffic from the internet.&lt;/li&gt;
&lt;li&gt;Distributes requests across multiple servers to keep your app reliable and scalable.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Application Tier – Amazon EC2 in private subnets&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;Runs the &lt;strong&gt;business logic&lt;/strong&gt; of your application.&lt;/li&gt;
&lt;li&gt;EC2 instances handle incoming requests, execute your code, and interact with the database.&lt;/li&gt;
&lt;li&gt;Hosting them in &lt;strong&gt;private subnets&lt;/strong&gt; enhances security by preventing direct internet access.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Database Tier – Amazon RDS in private subnets&lt;/strong&gt;

&lt;ul&gt;
&lt;li&gt;Stores and manages your &lt;strong&gt;application data&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Provides automatic backups, scaling, and patching as a &lt;strong&gt;fully managed service&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Ensures your data remains secure, consistent, and highly available.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Additional supporting services can strengthen the architecture:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Bastion Host (EC2 in a public subnet):&lt;/strong&gt; allows secure administrative access to private servers.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Amazon S3:&lt;/strong&gt; offers durable object storage for static assets, images, or backups.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Hands-on walkthrough to launch your own 3-tier web app in &lt;strong&gt;5 minutes&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;If you search online, you’ll find many tutorials about how to set up a 3-tier web app on AWS manually. They involve creating VPCs, configuring subnets, launching EC2s, attaching load balancers, provisioning RDS, and so on.&lt;/p&gt;

&lt;p&gt;But there are associated challenges:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Those tutorials are time-consuming to read and follow.&lt;/li&gt;
&lt;li&gt;Every step requires attention to detail, and even small mistakes can cause security or connectivity issues.&lt;/li&gt;
&lt;li&gt;Beginners often feel overwhelmed by the number of services and configurations involved.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is where our AI-powered tool - The Backend agent for AWS - makes things so much simpler. With our AI-powered solution, you don’t need to spend hours following step-by-step guides. Instead:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Tell us about your goals.&lt;/li&gt;
&lt;li&gt;The agent will determine the configurations required to achieve your goals.&lt;/li&gt;
&lt;li&gt;The agent automatically creates a CloudFormation template customized for your selected setup. A CloudFormation template is a simple text file that defines all the AWS resources you want to create and manage together as a single unit, called a &lt;em&gt;stack&lt;/em&gt;. Any resources deployed through this template can be managed, modified, or deleted just like those you configure manually in the AWS Console.&lt;/li&gt;
&lt;li&gt;Deploy all services with the cloudformation template in one click. It covers the entire 3-tier architecture  — including an Application Load Balancer in public subnets, EC2 instances in private subnets, and an RDS database safely tucked away in the data tier.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Whether you’re a beginner learning AWS or a team looking to save time on repetitive infrastructure work, our product makes building a 3-tier web application easier than ever. &lt;/p&gt;

&lt;p&gt;Let’s see how to use the tool to set up a 3-tier web application in minutes.&lt;/p&gt;

&lt;p&gt;1.After logging in, click &lt;strong&gt;Next&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqlf886681slviwnla2ue.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqlf886681slviwnla2ue.png" alt=" " width="525" height="490"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;2.&lt;strong&gt;Choose a region&lt;/strong&gt; where you want to deploy your resources, and click &lt;strong&gt;Next&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F21ee7ofnq2hs6qsmzedz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F21ee7ofnq2hs6qsmzedz.png" alt=" " width="627" height="944"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;3.There are five common use cases. You can select one or multiple of them depending on your needs. For a 3 tier web application, choose &lt;strong&gt;“I want to host a website or web application.”&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgljixoc9o6oa8xq05lxr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgljixoc9o6oa8xq05lxr.png" alt=" " width="637" height="746"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;4.You’ll be asked whether you want to provide a domain name to enable &lt;a href="https://www.cloudflare.com/learning/ssl/what-is-https/" rel="noopener noreferrer"&gt;https&lt;/a&gt; configuration. If you select Yes, there will be some additional setup questions. In this demonstration, we will select &lt;strong&gt;“No”&lt;/strong&gt; to proceed without HTTPS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs5cl7e1rfr9d5wvfnccb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs5cl7e1rfr9d5wvfnccb.png" alt=" " width="729" height="617"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;5.A summary page will show the resources that will be created, along with a detailed cost estimation breakdown. You can also make customizations to the services.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fg3pd0q99asj3hpq99xqi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fg3pd0q99asj3hpq99xqi.png" alt=" " width="800" height="590"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fuc741r6i8hic4kalrpb1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fuc741r6i8hic4kalrpb1.png" alt=" " width="677" height="895"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fharowmyw8nxqunqq2oc1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fharowmyw8nxqunqq2oc1.png" alt=" " width="591" height="525"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbsb7ay1rqh0450d875pb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbsb7ay1rqh0450d875pb.png" alt=" " width="630" height="856"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;6.The agent will generate a &lt;strong&gt;CloudFormation template&lt;/strong&gt;. A CloudFormation template is a text file written in JSON or YAML format that defines the AWS resources you want to provision and manage as a single unit, known as a "stack.” You can edit the script if needed. If you are not familiar, just leave it as-is. Click &lt;strong&gt;Next&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhw1wrqq2dw4o2n8k64mq.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhw1wrqq2dw4o2n8k64mq.png" alt=" " width="704" height="874"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;7.Provide a stack name. Click &lt;strong&gt;OK&lt;/strong&gt; to continue.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Foej3bvt9tzc3kcngrk05.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Foej3bvt9tzc3kcngrk05.png" alt=" " width="537" height="630"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;8.Click on the link. This will open the &lt;strong&gt;CloudFormation Quick Create Stack&lt;/strong&gt; page in your AWS account. If you have not yet, please login to AWS.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5of5dqjl481btwpvi1ll.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5of5dqjl481btwpvi1ll.png" alt=" " width="520" height="824"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;9.On the &lt;strong&gt;Quick Create Stack&lt;/strong&gt; page, scroll down and click &lt;strong&gt;Create stack&lt;/strong&gt;. If prompted to acknowledge that “AWS CloudFormation might create IAM resources with custom names,” check the box.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F12u8dpnld3y5n0ihljhh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F12u8dpnld3y5n0ihljhh.png" alt=" " width="800" height="129"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;10.CloudFormation will now create all required resources. While it runs, you can return to the backend agent to view the &lt;strong&gt;“How to Get Started”&lt;/strong&gt; instructions.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fiaobt4hlmcepyqy0kocb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fiaobt4hlmcepyqy0kocb.png" alt=" " width="719" height="950"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyl8978emgzpjbkdvzq62.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyl8978emgzpjbkdvzq62.png" alt=" " width="646" height="575"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;11.You can monitor the status of the resource creations under the CloudFormation &lt;strong&gt;Resources&lt;/strong&gt; tab. Once they are all “CREATE_COMPLETE”, the services are all set up.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Feudtgbyhu76zi4hf03i3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Feudtgbyhu76zi4hf03i3.png" alt=" " width="800" height="1175"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;That’s it! You now have a fully functioning 3 tier architecture ready to use.&lt;/p&gt;

&lt;p&gt;If you prefer, you can watch the video walkthrough &lt;a href="https://www.youtube.com/watch?v=ByKyEpOQJo0" rel="noopener noreferrer"&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Wrapping Up
&lt;/h2&gt;

&lt;p&gt;In this article, you learned what is the 3-tier web application architecture:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Presentation Tier&lt;/strong&gt; – where users interact with the app.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Application Tier&lt;/strong&gt; – where business logic is executed.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Database Tier&lt;/strong&gt; – where data is kept safe.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But setting up everything manually can be very time-consuming. That’s why we created the AI-powered Backend Agent for AWS. With just a few clicks, you can set up your infrastructure and skip directly to deploying your web application. It helps you avoid the complexity, while still giving you the flexibility to customize.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fr73ntpyekn437ci17pf0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fr73ntpyekn437ci17pf0.png" alt=" " width="800" height="388"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The Backend Agent for AWS is currently in beta and is free to use. Try out the agent &lt;a href="https://skylineopsai.com/AWS-Backend-agent" rel="noopener noreferrer"&gt;here&lt;/a&gt; and don’t hesitate to share your experience with us. We can’t wait to see what you’ll build!&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>aws</category>
      <category>ai</category>
      <category>cloudcomputing</category>
    </item>
    <item>
      <title>Launching Your First Website on AWS - Manually and Automatically with an AI Agent</title>
      <dc:creator>Alex Qu</dc:creator>
      <pubDate>Mon, 13 Oct 2025 06:18:30 +0000</pubDate>
      <link>https://dev.to/alex_qu_5a79e160e51d453ea/beginners-guide-launching-your-first-aws-website-step-by-step-or-with-ai-in-minutes-2bad</link>
      <guid>https://dev.to/alex_qu_5a79e160e51d453ea/beginners-guide-launching-your-first-aws-website-step-by-step-or-with-ai-in-minutes-2bad</guid>
      <description>&lt;p&gt;In this tutorial, we'll show you how to set up a working website on AWS with essential compute and networking configuration. Normally, this means spinning up an EC2 instance, configuring a VPC, subnets, route tables, gateways, security groups, installing &lt;a href="https://nginx.org/" rel="noopener noreferrer"&gt;Nginx&lt;/a&gt;, and finally serving a "Hello World" page. It's a lot of moving parts - and one wrong click can break the setup.&lt;/p&gt;

&lt;p&gt;That's why we built an &lt;a href="https://skylineopsai.com/AWS-Backend-agent" rel="noopener noreferrer"&gt;AI agent&lt;/a&gt; to do it all for you. Instead of spending hours juggling AWS settings, you can launch a website in a complete, production-ready environment in &lt;strong&gt;under three minutes&lt;/strong&gt; - no prior AWS experience required. If you want to skip all the hassle and use the agent instead, scroll down to “&lt;strong&gt;A Faster Way&lt;/strong&gt;”. You can also directly download the agent &lt;a href="https://skylineopsai.com/AWS-Backend-agent" rel="noopener noreferrer"&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;If you'd still like to understand how AWS works under the hood, keep reading - we'll walk you through the manual process step by step.&lt;/p&gt;

&lt;h2&gt;
  
  
  Prerequisite: Permissions
&lt;/h2&gt;

&lt;p&gt;Log into you AWS account and select the region where you want to create AWS resources. You'll need permissions to create and manage VPC and EC2 resources.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;If you're using an IAM user or role, make sure you have either AmazonVPCFullAccess and AmazonEC2FullAccess or equivalent permissions.&lt;/li&gt;
&lt;li&gt;If you're signing in with the root account, these permissions are already included by default - but keep in mind that AWS recommends creating an admin user instead of using root for day-to-day work.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Part 1: Set up networking (VPC)
&lt;/h2&gt;

&lt;p&gt;AWS EC2 resources live inside a VPC (Virtual Private Cloud), which is a logically isolated virtual network. AWS provides a "default VPC" out of the box, but in this guide we'll follow best practices and create our own custom VPC.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 1: Create a VPC
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Search and navigate to VPC service in the AWS Management Console.&lt;/li&gt;
&lt;li&gt;Click Create VPC.&lt;/li&gt;
&lt;li&gt;Select VPC only.&lt;/li&gt;
&lt;li&gt;Give it a name, e.g. app-vpc&lt;/li&gt;
&lt;li&gt;Set the IPv4 CIDR block to 10.0.0.0/16 (a private network range).&lt;/li&gt;
&lt;li&gt;Leave other settings as default and click Create VPC.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fodutjpke34beb90rt1fu.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fodutjpke34beb90rt1fu.png" alt=" " width="800" height="603"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 2: Create subnets
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;In VPC dashboard page, from the left menu, click &lt;strong&gt;Subnets → Create subnet&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Choose your VPC (&lt;code&gt;app-vpc&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Give it a name: &lt;code&gt;public-subnet-01&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Pick an Availability Zone, or you can leave it to &lt;strong&gt;No preference&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;IPv4 CIDR block: &lt;code&gt;10.0.1.0/24&lt;/code&gt;. (The private IP segment for the subnet)&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Create subnet&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Now we have one public subnet.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvrsfajl0lhv09q2124zj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvrsfajl0lhv09q2124zj.png" alt=" " width="800" height="551"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 3: Create an Internet Gateway
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;In VPC dashboard page, from the left menu, click &lt;strong&gt;Internet Gateways → Create internet gateway&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Give it a name &lt;code&gt;app-igw&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Create internet gateway&lt;/strong&gt;, then &lt;strong&gt;Actions → Attach to VPC&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Attach it to app-vpc.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu3pv4y4rvr59264ns3ah.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu3pv4y4rvr59264ns3ah.png" alt=" " width="800" height="261"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 4: Set up a Route Table
&lt;/h3&gt;

&lt;p&gt;A route table tells the subnet how traffic flows.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;In VPC dashboard page, from the left menu, click &lt;strong&gt;Route Tables → Create route table&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Give it a name: &lt;code&gt;app-public-rtb&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Choose the VPC: &lt;code&gt;app-vpc&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Click on “&lt;strong&gt;Create route table&lt;/strong&gt;”.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fum3y5ugqzfwir0c8od03.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fum3y5ugqzfwir0c8od03.png" alt=" " width="800" height="265"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;5.Under &lt;strong&gt;Routes&lt;/strong&gt; section→ &lt;strong&gt;Edit routes → Add route&lt;/strong&gt;.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Destination: &lt;code&gt;0.0.0.0/0&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Target: Internet Gateway (&lt;code&gt;app-igw&lt;/code&gt;).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;6.Save changes.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu6wf1jjxn4ed5c6h4s5c.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu6wf1jjxn4ed5c6h4s5c.png" alt=" " width="800" height="174"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;7.Under &lt;strong&gt;"Subnet associations" section → Edit subnet associations&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Check the box of "&lt;strong&gt;public-subnet-01&lt;/strong&gt;"&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Save associations&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft3bp5yue6d0al5lmj2zh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft3bp5yue6d0al5lmj2zh.png" alt=" " width="800" height="178"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 5: Enable auto-assign public IP
&lt;/h3&gt;

&lt;p&gt;Our to-be-created EC2 instance will need to have a public IP.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;In VPC dashboard page, from the left menu, go to &lt;strong&gt;Subnets → click "public-subnet-01"&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Actions → Edit subnet settings&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Check &lt;strong&gt;Enable auto-assign public IPv4 address&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Click “&lt;strong&gt;Save&lt;/strong&gt;” in the bottom right corner.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Filmq8mfnn9k4zqfnvrnf.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Filmq8mfnn9k4zqfnvrnf.png" alt=" " width="800" height="362"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Now, we have a VPC with a subnet where we can host EC2 instances that connect to the internet.&lt;/p&gt;

&lt;h2&gt;
  
  
  Part 2: Launch your EC2 instance
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Search and navigate to &lt;strong&gt;EC2&lt;/strong&gt; service in the AWS Management Console. Click &lt;strong&gt;Launch instance&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Give it a name: &lt;code&gt;nginx-app&lt;/code&gt; (just an example).&lt;/li&gt;
&lt;li&gt;For &lt;strong&gt;Application and OS Images&lt;/strong&gt;, choose the AMI: &lt;strong&gt;Amazon Linux 2023 Kernel-6.1 AMI&lt;/strong&gt; (It should be the first option of the list, and free tier eligible).&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvq0l0ts8ze6jzem7cuo7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvq0l0ts8ze6jzem7cuo7.png" alt=" " width="800" height="522"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;4.&lt;strong&gt;Instance type: t2.micro&lt;/strong&gt; (it should be the first option of the list, and free tier eligible).&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fey3o9c4zv9s0ilgyrrf0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fey3o9c4zv9s0ilgyrrf0.png" alt=" " width="800" height="144"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;5.&lt;strong&gt;Key pair&lt;/strong&gt; (if you already have an SSH key pair in the region and know how to use it, select your key for the drop down menu, and skip this step.)&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Click &lt;strong&gt;Create new key pair&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Give it a name &lt;code&gt;app-keypair&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Leave everything else as default, and &lt;strong&gt;Create Key pair&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Find the path of .pem file, for mac, it's commonly in Downloads folder.&lt;/li&gt;
&lt;li&gt;Open a terminal, and then move the key file to .ssh directory &lt;code&gt;mv ~/Downloads/app-keypair.pem ~/.ssh/app-keypair.pem&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Secure the permission of the key file &lt;code&gt;chmod 400 ~/.ssh/app-keypair.pem&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fx5aoi9ladd060iqei4it.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fx5aoi9ladd060iqei4it.png" alt=" " width="523" height="510"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffts49c1r52al26kvl4do.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffts49c1r52al26kvl4do.png" alt=" " width="800" height="94"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;6.&lt;strong&gt;Network settings&lt;/strong&gt;. Click &lt;strong&gt;Edit&lt;/strong&gt;.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Choose our newly created VPC: &lt;code&gt;app-vpc&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Subnet: &lt;code&gt;public-subnet-01&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Leave it as &lt;strong&gt;Auto-assign public IP: enabled&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0cvr76rek36x0layutzq.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0cvr76rek36x0layutzq.png" alt=" " width="800" height="275"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Create security group&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;Give it a name: &lt;code&gt;app-sg&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Description&lt;/strong&gt;: "Allow ssh from me and http traffic from anywhere"&lt;/li&gt;
&lt;li&gt;Allow &lt;strong&gt;22 (SSH)&lt;/strong&gt; from your IP&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Add security group rule&lt;/strong&gt; to allow &lt;strong&gt;80 (HTTP)&lt;/strong&gt; from anywhere (0.0.0.0/0)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fh3ibpy7wxbvzbnud6ans.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fh3ibpy7wxbvzbnud6ans.png" alt=" " width="800" height="580"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;7.Click Launch instance on the right.&lt;/p&gt;

&lt;h2&gt;
  
  
  Part 3: Create a simple website
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Step 1: Connect to the EC2 instance
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;In EC2 dashboard, from the left, go to Instances → check the box of &lt;strong&gt;nginx-app&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Look for &lt;strong&gt;Public IPv4 address&lt;/strong&gt; in &lt;strong&gt;Details&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;From your local terminal, run &lt;code&gt;ssh -i ~/.ssh/app-keypair.pem ec2-user@&amp;lt;the public ip from step 2&amp;gt;&lt;/code&gt;, and type "yes".&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Now you are connected to the EC2 instance, a linux machine.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl3wmb96fpufmku13eegg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl3wmb96fpufmku13eegg.png" alt=" " width="800" height="267"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 2: Install and run Nginx
&lt;/h3&gt;

&lt;p&gt;1.Once you are connected to the EC2 instance, run the following:&lt;br&gt;
&lt;code&gt;sudo dnf update -y &lt;/code&gt;&lt;br&gt;
&lt;code&gt;sudo dnf install -y nginx &lt;/code&gt;&lt;br&gt;
&lt;code&gt;sudo systemctl enable --now nginx&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;2.Test Nginx by open http:// in a browser, you should be able to see:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzd2gscmwjrvasndcuq2x.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzd2gscmwjrvasndcuq2x.png" alt=" " width="800" height="345"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;3.Replace with a customized html file with the following code:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo tee /usr/share/nginx/html/index.html &amp;gt;/dev/null &amp;lt;&amp;lt;'EOF'
&amp;lt;!doctype html&amp;gt;
&amp;lt;html&amp;gt;
  &amp;lt;head&amp;gt;&amp;lt;meta charset="utf-8"&amp;gt;&amp;lt;title&amp;gt;Hello EC2&amp;lt;/title&amp;gt;&amp;lt;/head&amp;gt;
  &amp;lt;body style="font-family:sans-serif; text-align:center;"&amp;gt;
    &amp;lt;h1&amp;gt;Hello World&amp;lt;/h1&amp;gt;
    &amp;lt;p&amp;gt;This is my first website!&amp;lt;/p&amp;gt;
    &amp;lt;img src="&amp;lt;https://upload.wikimedia.org/wikipedia/commons/9/9a/Soyuz_TMA-9_launch.jpg&amp;gt;" 
         alt="Rocket" width="200"&amp;gt;
  &amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;
EOF
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then run &lt;code&gt;sudo systemctl reload nginx&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;4.Now you can check your website by opening the http:// again.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4xbzaevtxulnp5wi0l96.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4xbzaevtxulnp5wi0l96.png" alt=" " width="800" height="792"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Part 4: Clean up
&lt;/h2&gt;

&lt;p&gt;When you're done, don't forget to stop or terminate your EC2 instance to avoid charges. You can also delete the VPC and related resources.&lt;/p&gt;

&lt;h2&gt;
  
  
  A faster way
&lt;/h2&gt;

&lt;p&gt;This is why we have created the Backend Agent for AWS. It will help you accomplish the same thing in &lt;strong&gt;under three minutes (saving 90% of time).&lt;/strong&gt; You just need to answer a couple questions to describe your goal, the AI agent will then generate a read-to-deploy CloudFormation template and guide you through the one-click service deployment.&lt;/p&gt;

&lt;p&gt;Let's see how we will achieve the same with the agent.&lt;/p&gt;

&lt;p&gt;1.After logging in, click &lt;strong&gt;Next&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6lv0is5dliq6hmwu0wow.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6lv0is5dliq6hmwu0wow.png" alt=" " width="525" height="490"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;2.&lt;strong&gt;Choose a region&lt;/strong&gt; where you want to deploy your resources, and click &lt;strong&gt;Next&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fscmsoodhf5kfuczw7zla.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fscmsoodhf5kfuczw7zla.png" alt=" " width="627" height="944"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;3.Select the option &lt;strong&gt;"I want to run light-weight tasks on a cloud server."&lt;/strong&gt;, then click &lt;strong&gt;Next&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ff0zoimm08xwy9m3pcia9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ff0zoimm08xwy9m3pcia9.png" alt=" " width="581" height="701"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;4.A summary page will show the resources that will be created, along with a cost estimate. You can also make customizations to the services. Review this information before continuing.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3u6uhay35jclhctx5zy9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3u6uhay35jclhctx5zy9.png" alt=" " width="709" height="899"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu2prbp4jks9t3ezd5a4t.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu2prbp4jks9t3ezd5a4t.png" alt=" " width="558" height="556"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;5.The agent will now generate a &lt;strong&gt;CloudFormation template&lt;/strong&gt;. A CloudFormation template is a text file written in JSON or YAML format that defines the AWS resources you want to provision and manage as a single unit, known as a "stack." You can edit the script if needed, then click &lt;strong&gt;Next&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ficgm4ns74nvo70ott9or.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ficgm4ns74nvo70ott9or.png" alt=" " width="474" height="796"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;6.Provide a stack name. Click OK to continue.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyjdqbzl6il5uq0puiz56.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyjdqbzl6il5uq0puiz56.png" alt=" " width="500" height="567"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;7.Click the provided link or copy and paste it into your browser. This will open the &lt;strong&gt;CloudFormation Quick Create Stack&lt;/strong&gt; page in your AWS account (make sure you are already logged in to AWS).&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft4ygdzaojbeyu98axxaz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft4ygdzaojbeyu98axxaz.png" alt=" " width="800" height="1249"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;8.On the &lt;strong&gt;Quick Create Stack ** page, scroll down and click **Create stack&lt;/strong&gt;. If prompted to acknowledge that "AWS CloudFormation might create IAM resources with custom names," simply check the box.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7hneitp32wrby9vox7zr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7hneitp32wrby9vox7zr.png" alt=" " width="800" height="130"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;9.CloudFormation will now create all required resources (the networking and EC2 setup from Parts 1 and 2 of this tutorial). While it runs, you can return to the Backend Agent to view the "&lt;strong&gt;How to Get Started&lt;/strong&gt;" instructions.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2nuu4p1a9j3fedcfw46p.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2nuu4p1a9j3fedcfw46p.png" alt=" " width="627" height="838"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;10.Once the CloudFormation stack has finished creating, you're ready to continue with &lt;strong&gt;Part 3&lt;/strong&gt; of this tutorial to configure Nginx and launch your website. You can review your resources under the CloudFormation &lt;strong&gt;Resources&lt;/strong&gt; tab.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq50sb1fifgj6pt9j2d13.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq50sb1fifgj6pt9j2d13.png" alt=" " width="800" height="655"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Wrapping Up
&lt;/h2&gt;

&lt;p&gt;In this tutorial, you learned how to build a simple website on AWS from the ground up:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Creating the necessary networking infrastructure (VPC, subnets, Internet Gateway, route table, and security group).&lt;/li&gt;
&lt;li&gt;Launching and configuring an EC2 instance.&lt;/li&gt;
&lt;li&gt;Installing Nginx and serving a custom web page.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But as you saw, doing everything manually can be time-consuming. That's why we created the AI-powered Backend Agent. With just a few clicks, your can set up your infrastructure, and you can skip directly to configuring your website. You will avoid the complexity, while still having the flexibility to customize.&lt;/p&gt;

&lt;p&gt;The Backend Agent for AWS is currently in beta and is free to use. Try out the agent &lt;a href="https://skylineopsai.com/AWS-Backend-agent" rel="noopener noreferrer"&gt;here&lt;/a&gt; and don’t hesitate to share your experience with us. We can’t wait to see what you’ll build!&lt;/p&gt;

</description>
      <category>aws</category>
      <category>webdev</category>
      <category>ai</category>
      <category>cloudcomputing</category>
    </item>
  </channel>
</rss>
