I\'ve two android applications on same LAN provided by WIFI :
I was looking for the same solution and found NanoHTTPD - an extremely simple HTTP request handling server class. You can find the source and very easy to understand samples at https://github.com/NanoHttpd