Skip to content

kevinnadar22/http-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Zero-Framework Notes App

Built from absolute scratch - Pure Python, vanilla JavaScript, and HTML/CSS. No Express, No React, No Flask, No databases.

Notes App Interface

What Makes This Special

  • 100% Framework-Free Backend: Raw Python sockets, manual HTTP parsing, custom routing
  • Pure Vanilla Frontend: Zero JavaScript frameworks - just DOM manipulation and fetch API
  • Custom Database: JSON-based ORM built from scratch with auto-persistence
  • Manual HTTP Protocol: Hand-crafted request/response handling
  • Async Non-blocking Server: Built with Python select for concurrent connections

Learning Journey

This project was my learning of low-level web fundamentals:

  • Understanding HTTP protocol from ground up
  • Socket programming and network communication
  • Building database abstractions without ORMs

How the Communication Happens

  1. A client (e.g., browser) initiates a connection to the server over TCP.

alt text

  1. Once connected, the client sends an HTTP request with headers.

  2. For example, accessing openai.com/pricing would send:

    GET /pricing HTTP/1.1
    Host: openai.com
    Content-Type: text/html
    

alt text

  1. The server reads the request, processes it, and sends an appropriate HTTP response.

  2. The connection may then be closed or kept alive based on the headers.

Next Goal: Building a mini web framework from these learnings

Quick Start

# Clone and run - that's it!
git clone https://github.com/kevinnadar22/HTTP-Server
cd HTTP-Server
python main.py

Open http://localhost:8000 - Your notes app is ready! ✓

✓ Features

  • Full CRUD (Create, Read, Update, Delete)
  • Real-time search and responsive design
  • Auto-saving database and modern UI
  • Concurrent connections and error handling
  • HTTP compliance and RESTful API

UI Demo

Notes App Interface

🛠 Technical Stack

Layer Technology Why No Framework?
Server Raw Python Sockets Learn HTTP fundamentals
Database Custom JSON ORM Understand data persistence
Frontend Vanilla JS + CSS Master DOM manipulation

Contact

Feel free to reach out:

About

Zero-Framework Notes App using raw Python sockets, JSON

Topics

Resources

Stars

Watchers

Forks