(CNN) -- A convicted sex offender who was on the run for nearly a week with his 14-year-old niece is now in the custody of Texas law enforcement, according to authorities.
Matthew Mallory, 35, of Kingfisher County, Oklahoma, is being held in a San Antonio jail. Bexar County Sheriff's Office deputies caught the fugitive Tuesday night outside the city limits, Deputy U.S. Marshall Tom Smith said on HLN's Nancy Grace.
Mallory's niece, identified by the Kingfisher County Sheriff's Office as Airel Daphane Ann Mallory, was "okay" but a little dehydrated, Smith said.
Airel had been missing since April 5, according to authorities. Oklahoma authorities had issued an arrest warrant against Matthew Mallory for abandoning another child.
A rancher spotted Airel and Matthew Mallory, her uncle by marriage, on Tuesday and immediately called a relative who works for the Bexar County Sheriff's Office.
The rancher, said Smith, "was out feeding his stock and he saw them behind a trailer changing clothes.''
Smith said Airel and Mallory did not see the rancher.
Sheriffs' deputies arrived, "snuck up on him, tackled him and got him in handcuffs. End of story,'' Smith said.
The Ford Taurus Mallory used to flee with Airel was recovered under a rural Southeast Texas bridge on Monday, days after they left the home of the girl's mother in Oklahoma, where Mallory was living, according to authorities.
The two were seen on surveillance video at a Walmart and Walgreens in San Antonio on Sunday, according to law enforcement.
Mallory's long criminal record, which dates back to 1994, includes second degree rape, assault and battery, intimidation of a witness and failure to comply with the sex offender registration act, according to court records.
On April 6, an Oklahoma district attorney received an emergency order to remove an infant and young child from the home.
Authorities say Airel has a baby and DNA paternity tests will be conducted to identify the father.
''If it happens to be Matthew's, then I hope he gets what he deserves,'' Smith said.