Method 1: Find Location of Every Occurrence unlist(gregexpr('character', my_string)) Method 2: Find Location of First Occurrence unlist(gregexpr('character', my_string))[1] Method 3: Find Location of Last Occurrence tail(unlist(gregexpr('character', my_string)), n=1) Method 4: Find Total Number of Occurrences length(unlist(gregexpr('character', my_string)))