# Enable URL rewriting
RewriteEngine On

# Set the base URL for rewrite rules
RewriteBase /

# Ensure index.html is not rewritten
RewriteRule ^index\.html$ - [L]

# Check if the requested file or directory does not exist
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

# Redirect all other requests to index.html
RewriteRule . /index.html [L]