There is a requirement to encode your parameter's value before concatenating them to the URL.
Backslash \ is special character which have to be escaped as %6C
Escaping example:
String myValue = "para\\with\\backslash";
String yourURLStr = "http://host.com?para=" + java.net.URLEncoder.encode(myValue, "UTF-8"); java.net.URL url = new java.net.URL(yourURLStr);
The result is http://host.com?para=para%6Cwith%6Cbackslash which is a formatted url string.