Your expression may be as simple as \d+ , given the assumption that there will be only one number in your input. Still in this assumption, using ToString in the resulting match, you will get what you are looking for.
var regex = Regex.Match("/{localLink:1301}", @"\d+"); var result = regex.ToString();
source share