What's the difference between EscapeUriString and EscapeDataString?
If only deal with url encoding, I should use EscapeUriString ? Use EscapeDataString always (for more info about why, see Livven's answer below) Edit : removed dead link to how the two differ on encoding I didn't find the existing answers satisfactory so I decided to dig a little deeper to settle this issue. Surprisingly, the answer is very simple: There is no valid reason to ever use Uri.EscapeUriString . If you need to percent-encode a string, always use Uri.EscapeDataString . Why is this? According to the documentation : Use the EscapeUriString method to prepare an unescaped URI string to be