Skip to main content

How sites work on Flexweg

How sites work on Flexweg

Flexweg hosts static websites. You upload a folder of HTML, CSS, JavaScript and media files, and those exact files are served from your domain. There is no PHP, no Node.js, no database — which is exactly what makes static sites fast, reliable and inexpensive to host.

This page explains how Flexweg maps URLs to the files you upload, so you can predict where every page and asset will live before you hit "deploy".

Supported file types

Any file with one of the extensions below can be uploaded and served. Anything else is rejected.

CategoryExtensions
Web.html, .css, .js, .json, .xml, .txt
Images.jpg, .png, .gif, .svg, .webp, .ico
Documents.pdf
Fonts.woff, .woff2, .ttf, .otf
Video.mp4, .webm, .ogg, .mov

Flexweg automatically sends the correct Content-Type header so browsers know how to display each file.

The single rule: URLs map to files

Whatever path a visitor types after your domain, Flexweg looks for a file at that path inside your upload:

Visitor asks for: mysite.flexweg.com/about.html
Flexweg serves: /about.html (from your upload)

That's the whole model. The only exception — and it's a very useful one — concerns folders.

The index.html convention

When a URL points to a folder (a path ending with /, or that doesn't map to a specific file), Flexweg looks for a file called index.html inside that folder and serves it.

Visitor asks for: mysite.flexweg.com/
Flexweg serves: /index.html

Visitor asks for: mysite.flexweg.com/products/
Flexweg serves: /products/index.html

This lets you write clean URLs like /products/ instead of /products/index.html.

Automatic redirect of /index.html

If someone explicitly types the index.html part, Flexweg redirects them to the clean URL:

Visitor typesFlexweg redirects to
mysite.flexweg.com/index.htmlmysite.flexweg.com/
mysite.flexweg.com/blog/index.htmlmysite.flexweg.com/blog/

Why it matters: it prevents two different URLs from showing the same page, which search engines penalize ("duplicate content").

A concrete example

Suppose you upload this folder structure:

mysite/
├── index.html
├── about.html
├── products/
│ ├── index.html
│ ├── chair.html
│ └── table.html
├── blog/
│ ├── index.html
│ └── welcome.html
└── assets/
├── style.css
├── main.js
└── logo.png

Here is how every URL resolves:

URLFile served
mysite.flexweg.com//index.html
mysite.flexweg.com/about.html/about.html
mysite.flexweg.com/products//products/index.html
mysite.flexweg.com/products/chair.html/products/chair.html
mysite.flexweg.com/blog//blog/index.html
mysite.flexweg.com/blog/welcome.html/blog/welcome.html
mysite.flexweg.com/assets/style.css/assets/style.css
mysite.flexweg.com/assets/logo.png/assets/logo.png

The rule is consistent: what you upload is what you get.

How styles, scripts and images are loaded

When a browser requests index.html, Flexweg returns only that file. The browser then reads the HTML, finds the references to CSS, JS and images, and requests each of them separately. Flexweg serves each one from wherever it sits in your upload.

A typical index.html looks like this:

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>My site</title>

<!-- Stylesheet -->
<link rel="stylesheet" href="/assets/style.css">

<!-- Favicon -->
<link rel="icon" href="/assets/favicon.ico">
</head>
<body>
<h1>Welcome</h1>
<img src="/assets/logo.png" alt="My logo">

<!-- JavaScript, deferred so it runs after the page parses -->
<script src="/assets/main.js" defer></script>
</body>
</html>

Every href and src attribute triggers an additional request. The browser sees:

  1. GET / → Flexweg returns /index.html
  2. GET /assets/style.css → Flexweg returns that file
  3. GET /assets/favicon.ico → Flexweg returns that file
  4. GET /assets/logo.png → Flexweg returns that file
  5. GET /assets/main.js → Flexweg returns that file

If any of those files is missing or has a typo in its path, the browser shows a broken image or an unstyled page. Always check the Network tab of your browser DevTools when something looks wrong — it tells you exactly which file failed.

Absolute vs relative paths

You have two ways to reference an asset:

Path styleExampleResolves from…
Absolute (starts with /)/assets/logo.pngThe site root
Relative (no leading /)assets/logo.png or ../logo.pngThe current HTML file's folder

Recommendation: use absolute paths (/assets/...) whenever possible. They work identically from every page on your site, whereas relative paths break as soon as you move a file into a subfolder.

Building your first site — step by step

Here is the shortest path from an empty folder to a live site.

1. Create the folder structure locally

Open any text editor and create these three files:

my-first-site/
├── index.html
└── assets/
└── style.css

2. Write the HTML

index.html:

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>My first Flexweg site</title>
<link rel="stylesheet" href="/assets/style.css">
</head>
<body>
<h1>Hello, Flexweg</h1>
<p>This static site is served directly from my upload.</p>
</body>
</html>

3. Add some styles

assets/style.css:

body {
font-family: system-ui, -apple-system, sans-serif;
max-width: 640px;
margin: 3rem auto;
padding: 0 1rem;
line-height: 1.6;
color: #1e293b;
}

h1 {
color: #667eea;
letter-spacing: -0.02em;
}

4. Upload to Flexweg

Zip the my-first-site/ folder (or push it through your usual deploy pipeline), then upload it to your Flexweg site. The entire folder is now accessible from your domain.

5. Visit the site

Open mysite.flexweg.com. The browser asks for /, Flexweg finds /index.html, returns it, and the page appears. Any change to the files goes live within seconds of re-uploading.

Adding a second page

Suppose you want an "About" page reachable at mysite.flexweg.com/about. You have two options — both valid, but one is cleaner.

Create a new folder about/ containing its own index.html:

my-first-site/
├── index.html
├── about/
│ └── index.html
└── assets/
└── style.css

Visiting mysite.flexweg.com/about serves /about/index.html. No .html in the URL — tidy and shareable.

Option B — Flat file

Create about.html at the root:

my-first-site/
├── index.html
├── about.html
└── assets/
└── style.css

Visiting mysite.flexweg.com/about.html serves that file. The .html is visible in the URL.

Most sites mix both: single top-level pages as .html files, and grouped content in folders.

Linking between pages

Use plain anchor tags. Flexweg doesn't need a framework or build step for navigation:

<nav>
<a href="/">Home</a>
<a href="/about/">About</a>
<a href="/products/">Products</a>
</nav>

Absolute paths (/about/) keep navigation consistent from any page of the site.

Organising a larger site

Once you have more than a handful of pages, a predictable folder layout saves time:

mysite/
├── index.html
├── about/
│ └── index.html
├── products/
│ ├── index.html ← product listing
│ ├── chair/
│ │ └── index.html ← single product page
│ └── table/
│ └── index.html
├── blog/
│ ├── index.html ← blog home
│ └── 2026-launch/
│ └── index.html ← a blog post
└── assets/
├── css/
│ └── style.css
├── js/
│ └── main.js
├── img/
│ ├── logo.png
│ └── hero.jpg
└── fonts/
└── inter.woff2

Each section (about, products, blog) lives in its own folder with an index.html as the entry point. All shared assets live under /assets/ — which means there is exactly one path to update when you change the logo.

Common pitfalls

  • Missing index.html in a folder. If you create /products/ without an index.html, typing mysite.flexweg.com/products/ returns a 404. Either add the file, or link directly to an existing child page like /products/chair.html.
  • Case sensitivity. Hero.jpg and hero.jpg are different files on Flexweg. A site that works on Windows (case-insensitive) can break after upload. Keep filenames lowercase by convention.
  • Broken relative paths. A <img src="logo.png"> inside /products/index.html looks for /products/logo.png, not /logo.png. Prefer absolute paths.
  • Forgotten file types. .docx, .zip and other extensions are rejected. If you need to offer a downloadable asset, convert it to PDF (or host the file elsewhere and link to it).

What static sites cannot do

Static hosting is powerful because it's simple — Flexweg serves files, nothing else. If your site needs any of the following, you need to combine it with Flexweg's dynamic features:

  • Storing data submitted through a form
  • User accounts and authentication
  • Per-visitor personalised content
  • Content that updates without a re-upload

For all of those, your static site stays the same and the dynamic parts are handled through Flexweg's REST API, called from the browser. The static site handles presentation; the API handles data.