Two things, one is that you don't need the leading and trailing "/", that's when you're using js. Second if the only text you're testing contains the number you either need to trim it to remove the trailing space ("$" means "ends with" and your text ends with a space, not a number), or drop the "$", whichever you think gives the best solution.
var varText = "DE55680501010022067234 ";
Regex reg = new Regex(@"^DE\d{20}");
if (!reg.IsMatch(varText))
{
Response.Write("not valid");
}
reg = new Regex(@"^DE\d{20}$");
if (!reg.IsMatch(varText.Trim()))
{
Response.Write("not valid");
}