1 | initial version |
^+?\d{0,3}?\d{10}$
Explanation: - ^+? matches an optional plus sign at the beginning - \d{0,3}? matches up to 3 digit country code, optional (the ? makes it optional) - \d{10} matches the remaining 10 digits of the mobile number - $ matches the end of the string