webutility.urlencode space

C#
Uri.EscapeDataString("your not escaped url")
Source

Also in C#: