regex for mobile number validation in javascript code example Example 1: regex pattern for mobile number /^(\+\d{1,3}[- ]?)?\d{10}$/ Example 2: regex for mobile number ^\+*[0-9]+$