# Allow HTTP and HTTPS

When you deploy an application on your server, you might want it accessible via
a browser, either via `HTTP` or `HTTPS`. To do that, you need **ingress** rules in a security
group to allow communication on __port 80__ (`HTTP`) and __port 443__ (`HTTPS`).

* Create a new security group called **frontend**
* Add a first rule: `INGRESS, TCP, CIDR 0.0.0.0/0, port 80-80`
* Add another rule: `INGRESS, TCP, CIDR 0.0.0.0/0, port 443-443`

Now the instances using this security group will allow traffic from any IP
(CIDR 0.0.0.0/0) on port 80 and 443.

![](sg-frontend.png "Frontend Security Group")

Add this Security Group to the instance that will be accessed via `HTTP` and `HTTPS`.

> [!NOTE]
> If your instance only has this Security Group, you will not be able to access it via `SSH`.
