The Internet Direct (Indy) 10 HTTP server class TIdHTTPServer does support HTTP file upload with multipart/form-data encoding. The solution below is based on code in the Indy and Delphi newsgroups. Please note that a patch in the Indy library is required, as shown on Stackoverflow in Indy MIME decoding of Multipart/Form-Data Requests returns trailing CR/LF.

Usage

If the demo server runs, open a web browser and navigate to the URL http://127.0.0.1:8080, there you will find the upload form

Source

The full source code can be found here: Indy MIME decoding of Multipart/Form-Data Requests returns trailing CR/LF.