What is HTTP?

• HTTP stands for Hyper Text Transfer Protocol
• Communication between web servers and clients
• HTTP Requests / Responses
• Loading pages, from submit, Ajax calls


HTTP is Stateless

• Every request is completely independent
• Similar to transactions
• Programming, Local Storage, Cookies, Sessions are used to create enhanced user experience


What is HTTPS?

• HTTPS stands for Hyper Text Transfer Protocol Secure
• Data sent is encrypted
• Install certificate on web host


HTTP Methods

HTTP MethodsMeaning
GETRetrieve data from the server
POSTSubmit data to the server
PUTUpdate data already on the server
DELETERemove data from the server


HTTP Headers Fields


General HeaderResponse HeaderRequest Header
Request URIServerCookies
Request MethodSet-CookieAccept-xxx
Status CodeContent-TypeContent-Type
Remote AddressContent-LengthContent-Length
Referrer PolicyDateAuthorization


HTTP Status Codes

CategoryMeaningCommon Status Codes
1xx: InformationalReqeuest received / processing
2xx: SuccessSuccessfully received, understood and accepted200 - OK 201 - OK created
3xx: RedirectFurther action must be taken / redirect301 - Moved to new URL 304 - Not modified (Cached version)
4xx: Client ErrorRequest does not have what it needs400 - Bad request 401 - Unauthorized 404 - Not found
5xx: Server ErrorServer failed to fullfill an apparent valid request500 - Internal server error



• Major revision of HTTP (current HTTP 1.1_
• Under the hood changes
• Respond with more data
• Reduce latency by enabling full request and response multiplexing
◇ May get html, css, js, image files at the same time within 1 request
• Fast, efficient and secure


How to View HTTP Related Info

Browser: Dev Tools > Network
Express Server