cotestatnt/esp-fs-webserver
ESP32/ESP8266 webserver, WiFi manager and web editor Arduino library
๐ What's Changed
- docs: fix config file name references by @thehanslevi in https://github.com/cotestatnt/esp-fs-webserver/pull/80
- fix OTA update bug (issue https://github.com/cotestatnt/esp-fs-webserver/issues/79)
โจ New Contributors
- @thehanslevi made their first contribution in https://github.com/cotestatnt/esp-fs-webserver/pull/80
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/3.3.0...3.3.1
๐ฆ esp-fs-webserver 3.3.0
- This release improves `/setup` behavior, legacy storage migration, and WiFi event handling across ESP32 and ESP8266.
- It also completes the transition to the shared built-in page source repository for `/setup` and `/edit`, which is now the canonical source for the embedded web UI used by the sync library.
๐ฆ Highlights
- Added automatic migration from legacy `/config` storage to `/setup`
- Added WiFi connection and disconnection callbacks for ESP32 and ESP8266
- Improved `/setup` route handling and asset resolution
- Moved built-in `/setup` and `/edit` page development to the shared source repository
- Aligned the sync library with the shared WebSocket-based `/setup` frontend
๐ฆ Shared Built-In Pages
- The built-in `/setup` and `/edit` pages are now maintained from the shared source repository:
- [`fs-webserver-shared-pages`](https://github.com/cotestatnt/fs-webserver-shared-pages)
- This repository is now the canonical source for the embedded frontend assets used by the library.
- The sync library consumes the generated outputs from that shared project instead of maintaining separate duplicated page sources.
- The shared `/setup` frontend now uses a WebSocket-based interaction model, and the sync backend has been aligned to support the same shared frontend source and behavior where applicable.
โจ What's New
- New automatic migration logic detects legacy `/config/config.json`, moves setup assets to `/setup`, rewrites asset paths in the configuration, logs the migration, and restarts the device to apply changes
- New WiFi connection callback support is now available in the sync library both for ESP32 and ESP8266
- The sync backend has been aligned with the shared setup asset structure and shared frontend outputs
- The built-in frontend architecture is now aligned with the shared `/setup` and `/edit` source project
๐ Fixes
- Fixed setup asset handling after the move from legacy `/config` storage to canonical `/setup`
- Fixed mismatches between setup storage folder expectations and requested frontend asset paths
- Synchronized WiFi callback support with the async library
๐ฆ Compatibility Notes
- This version keeps backward compatibility in mind, but it also introduces new behavior around setup storage
- Devices still using legacy `/config` setup storage will be migrated automatically on boot
- WiFi callback signatures remain platform-native:
- ESP32 uses `WiFiEvent_t` and `WiFiEventInfo_t`
- ESP8266 uses `WiFiEventStationModeGotIP` and `WiFiEventStationModeDisconnected`
๐ฆ Full Summary
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/3.2.3...3.3.0
โจ ๐ New Features
- `saveOptionValue()` API: New public method that allows programmatically updating the value of a configuration option (identified by its label) directly from sketch code, without manually opening the configuration file. Supports all common types (`bool`, `int`, `float`, `String`, `const char*`).
๐ ๐ Bug Fixes
- Fix bug in option saving logic: Corrected `finalizeSectionsToRoot()` and `saveOptionValue()` to ensure already-persisted sections are not overwritten when no new sections are being added. Added helper methods `findElementByLabel()` and `adoptSavedConfigurationAsSessionDoc()` for more robust element lookup and update.
- Fix issue #76 โ ESP8266 compilation error: Resolved a build error caused by calling `fs::File::path()`, which is not available on ESP8266. Replaced with a cross-platform compatible approach.
- `friend class AsyncFsWebServer`: Added `friend` access for `AsyncFsWebServer` in `SetupConfigurator`, aligning permissions with those already granted to `FSWebServer`.
๐ฆ ๐จ UI Improvements
- Restyled `/setup` page: Updated CSS and layout of the configuration page with a modern look โ dark gradient background, cyan/blue accent palette, refined borders, shadows, and responsive layout.
- ---
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/3.2.2...3.2.3
๐ ๐ Improvements & Bug Fixes
- Comment support for each option: Enhanced `addOption` with support for comments.
- Boolean Options: Enhanced `addOption` for boolean values with comments and per-option grouping control.
- Fixed `setConfigSavedCallback`: Corrected the trigger mechanism when saving configuration files from the web UI.
- Fix README.md by @mhaberler in https://github.com/cotestatnt/esp-fs-webserver/pull/74
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/3.2.1...3.2.2
โจ New Features
- ESP32-P4 Support: Added initial fixes for ESP32-P4, including a new example for the Waveshare devkit. Updated `randomSeed` to use `esp_random()` for better compatibility and to prevent crashes on ESP32-P4.
- M5Stack Tab5 Target: Added support for M5Stack Tab5 with necessary incantations for proper operation.
๐ฆ Improvements and Optimizations
- CSS and JavaScript Fixes: Various fixes and improvements to styling and scripting, including logo fixes and example corrections.
๐ Documentation Updates
- Updated `SetupAndWiFi.md` with clarified captive portal descriptions and added details on IP address and mask configuration.
- Added an image to the Websocket Echarts README for better visual reference.
- General README updates and documentation enhancements.
๐ Other Changes
- Merged pull requests from contributors for ESP32-P4 fixes and random seed improvements.
- Minor internal commits preparing for release and code maintenance.
- For a complete list of all changes, view the full comparison on GitHub.
๐ What's Changed
- esp-hosted: initial fix for esp32-p4 by @mhaberler in https://github.com/cotestatnt/esp-fs-webserver/pull/73
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/3.2.0...3.2.1
๐ฆ Config Schema v2
- The `config.json` format has been updated to a hierarchical structure:
- Old format (v1): flat keys at root level
- New format (v2): structured with `_version`, `_meta`, `_state`, `_assets`, and `sections`
- Existing v1 configurations are automatically migrated at runtime. No manual intervention required.
- New structure:
- ```json
- {
- "_version": "2.0",
- + 15 more
๐ฆ Improvements
- Setup/UI: Major updates to `/setup` and `/edit` pages with refined styling and asset handling
- WiFi Service: Enhanced connection diagnostics and STA network configuration logging
- WebSocket: Improved random seeding on ESP32 using `esp_random()` for better security
- Captive Portal: Optimized flow and better IP configuration handling
๐ฆ WebSocket Telemetry Dashboard example
- Added new `websocketEcharts` example with a live real-time dashboard:
- Displays heap memory, max block size, and WiFi RSSI
- Built with [ECharts 5](https://echarts.apache.org/) for smooth animated charts
- Available in both `examples/` and `pio_examples/` directories
- Supports multiple themes (Aurora, Sunrise, Mono)
๐๏ธ Removals
- `highcharts` example has been replaced by the new `websocketEcharts` example
๐ฆ Key Improvements
- WiFi Password Encryption: Passwords are now encrypted using AES-256-CBC (with hardware support on ESP32) to protect saved credentials.
๐ฆ Advanced Credential Management:
- Support for multiple SSIDs with automatic selection based on the strongest signal.
- Improved UI for managing credentials (add, edit, delete).
- Ability to save WiFi credentials persistently with encryption.
๐ฆ Refreshed User Interface:
- Unicode icons instead of SVG to reduce size.
- Improvements to mobile responsiveness.
- Added credential management with tabs for multiple networks (if applicable).
- Added sections dedicated to password encryption and WiFi management in the README.
- Integrated Setup Page Refactoring: Complete overhaul of app.js, creds.js, style.css, and all.htm to support new features.
- Compatibility: Maintains backward compatibility with version 3.0.0, but some sketches may require minor updates to leverage new APIs.
- Compatibility Notes
- โ ๏ธ This is a release with minor breaking changes for WiFi credential management. Existing sketches should continue to work, but testing reconnection and encryption is recommended.
- + 5 more
๐ What's Changed
- align dev by @cotestatnt in https://github.com/cotestatnt/esp-fs-webserver/pull/68
- Dev by @cotestatnt in https://github.com/cotestatnt/esp-fs-webserver/pull/69
- aes include by @cotestatnt in https://github.com/cotestatnt/esp-fs-webserver/pull/70
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/3.0.0...3.1.0
๐ Changes
- Introduced a new lightweight `FSWebServer::Json` class that wraps the `cJSON` library
- Provides a simplified API for JSON serialization and deserialization without external heavy libraries
- Reduced memory footprint and improved performance on resource-constrained ESP devices
- Users no longer need to include `#include <ArduinoJson.h>` in their sketches
- Reorganized core library classes for better maintainability and logical separation of concerns
- Improved namespace organization within `FSWebServer` namespace
- Enhanced code modularity to support cleaner integrations
- JSON operations now use the new `FSWebServer::Json` class instead of ArduinoJson's `JsonDocument`, `JsonArray`, and `JsonObject `types
- + 2 more
๐ What's Changed
- Dev by @cotestatnt in https://github.com/cotestatnt/esp-fs-webserver/pull/66
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/2.0.10...3.0.0
๐ Changes
- Show DHCP IP address after connection
๐ What's Changed
- Add some config documentation to README by @AnasKhedr in https://github.com/cotestatnt/esp-fs-webserver/pull/64
โจ New Contributors
- @AnasKhedr made their first contribution in https://github.com/cotestatnt/esp-fs-webserver/pull/64
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/2.0.9...2.0.10
๐ Changes
- Fix Windows11 captive portal endpoints
๐ What's Changed
- updated header to resolve missing library header , moved variable otaDone from static to inside the class ( avoid warning) by @rommo911 in https://github.com/cotestatnt/esp-fs-webserver/pull/60
- added support to change credentials in runtime and some assertion after mem allocation bug by @rommo911 in https://github.com/cotestatnt/esp-fs-webserver/pull/61
- fixed some examples
โจ New Contributors
- @rommo911 made their first contribution in https://github.com/cotestatnt/esp-fs-webserver/pull/60
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/2.0.7...2.0.8
**Full Changelog**: https://github.com/cotestatnt/esp-fs-webserver/compare/2.0.6...2.0.7
๐ Changes
- solved websocket library conflicts if ArduinoWebSockets is installed
- ESP32 mDNS bug fix
๐ Changes
- Added option for requiring HTTP basic authentication on all pages.
- Added builtin websocket (based on [ArduinoWebSockets ](https://github.com/Links2004/arduinoWebSockets) library)
- WiFi scan now is perfomed in asyncrhonously mode
๐ What's Changed
- Add option for requiring HTTP basic authentication on all pages. by @sjmf in https://github.com/cotestatnt/esp-fs-webserver/pull/46
โจ New Contributors
- @sjmf made their first contribution in https://github.com/cotestatnt/esp-fs-webserver/pull/46
- Full Changelog: https://github.com/cotestatnt/esp-fs-webserver/compare/2.0.4...2.0.5
`/setup` web page decor (WiFi state info moved to header section)
๐ Changes
- AP IP Address now can be settled from user
- hostname and server port can be settled at runtime (for example loading it as configuration options)
๐ Changes
- Bug fix (when server was started without options like in simpleServer.ino, a bad config.json file was created)
๐ Changes
- drastically reduced the number of read/write accesses to the configuration file during setup:
- setup page fix ('/' character not needed in some situations)
- some examples updated
# Please read carefully: this is a breaking release! With version 2.x the `FSWebServer` class is directly inherited from the parent `WebServerClass`. Due to this important change, the class constructor has been completely revisited. If you want to update a project to this version, it is therefore necessary to make some changes. # Class constructor **OLD** ``` #ifdef ESP8266 ESP8266WebServer server(80); #elif defined(ESP32) WebServer server(80); #endif FSWebServer myWebServer(LittleFS, server); ``` **NEW** ``` FSWebServer myWebServer(LittleFS, 80); ``` # Updated and removed methods The `begin()` method of the parent class returns a void then the statement `if (myWebServer.begin())` is not valid and you need to call only `myWebServer.begin();` (without if statement). The method `addHandler()` was removed, the you need to use directly the parent class method `on()` # ACE web editor If you want to use the included page `/edit`, now it must be explicitly enabled during `setup()` or where you need. Since the information relating to the filesystem (label, maximum size and free space) is strictly related to the type of filesystem you want to use, it is necessary to pass a callback function that will provide this information Callback function ``` #ifdef ESP32 void getFsInfo(fsInfo_t* fsInfo) { fsInfo->fsName = "LittleFS"; fsInfo->totalBytes = LittleFS.totalBytes(); fsInfo->usedBytes = LittleFS.usedBytes(); } #else void getFsInfo(fsInfo_t* fsInfo) { fsInfo->fsName = "LittleFS"; } #endif ..... // Enable ACE FS file web editor and add FS info callback function myWebServer.enableFsCodeEditor(getFsInfo); ``` # Page authentication `/setup` and `/edit` built-in web pages can be restricted with user and password authentication ``` // set /setup and /edit page authentication myWebServer.setAuthentication("admin", "admin"); ``` # ArduinoJson 7.x The use of the ArduinoJson library has been adapted to the new 7.x version while maintaining compatibility with previous versions
-fix wifi connection -example updated **Full Changelog**: https://github.com/cotestatnt/esp-fs-webserver/compare/1.3.1...1.3.2
๐ Changes
- added manual WiFi configuration (IP, gateway, subnet)
- /setup and /config web pages updated
- serial log refactored
- /setup page configuration refactored (distinct class)
- capitve portal bug fix
- examples updated with some new API
๐ Changes
- added manual WiFi configuration (IP, gateway, subnet)
- `/setup` and `/config` web pages updated
- serial log refactored
- `/setup` page configuration refactored (distinct class)
- capitve portal bug fix
๐ Changes
- changed C++ formatting style to "WebKit"
- /setup web page can upload all content of folders ("data/" folder will be treated as root "/")
๐ Changes
- startWiFi() API changes
- /setup webpage can hadle OTA update
- examples updated
๐ Changes
- Fix esp8266 bug
๐ Changes
- setup webpage fix and optimization
- `webserver->enableDelay(false);` // yield() in `run()` method
๐ Changes
- `/setup` protocol bug
- added callback to `startWifi()` function
๐ Changes
- esp8266 bugfix
- removed button "about" from /setup page (credits as footer)
- better handling of special characters in password
