Java upload files by sending multipart request programmatically In this post, you will learn how to code a Java client program that upload files to a web server programmatically. In the article Upload file to servlet without using HTML form,we discussed how to fire an HTTP POST request to transfer a file to a server – but that request’s content type is not of multipart/form-data, so it may not wor