Martha McSally, Republican U.S. Senate candidate from Arizona, speaks during a campaign rally outside the Historic Yavapai County Courthouse in Prescott, Arizona, U.S., on Monday, Nov. 5, 2018. Surging turnout has both Republicans and Democrats proclaiming they stand to benefit, as polls show tight races up and down the ballot that will determine control of Congress, state houses and governors mansions nationwide. Photographer: Caitlin O'Hara/Bloomberg via Getty Images

Republican Arizona Gov. Doug Ducey will appoint Rep. Martha McSally to fill the late Sen. John McCain's seat.

McSally will succeed Sen. Jon Kyl, the longtime lawmaker who rejoined the Senate for only a few months following McCain's death in August. McSally, a 52-year-old congresswoman, will serve with Democrat Kyrsten Sinema in the next Congress. Sinema defeated McSally in the race for retiring GOP Sen. Jeff Flake's seat in November.

"I am humbled and grateful to have this opportunity to serve and be a voice for all Arizonans," McSally said in a statement Tuesday. "I look forward to working with Senator-Elect Kyrsten Sinema and getting to work from day one."

The Republican will have to run in a special election in 2020. Arizona will also hold an election for the seat in 2022, when McCain's original term ends. The state is considered one of Democrats' best pickup opportunities in 2020.

Some Republicans reportedly had concerns about McSally's ability to win statewide after her loss last month. Sinema, also a congresswoman, defeated her GOP opponent by about 2.5 percentage points in a state that has become increasingly purple. Trump carried Arizona in 2016, but only by around 3 percentage points.

Sinema was one of only two Democrats to flip a GOP-held Senate seat in this year's midterms. Republicans netted two seats in the elections, and will hold a 53-47 Senate majority in January.

Sinema will get sworn in on Jan. 3, before McSally, Ducey told reporters on Tuesday. The Democrat therefore will be the state's senior senator.

McSally has represented Arizona in the House since 2015. While she previously cast herself as a more center-right lawmaker, she had to take on a more pro-Trump stance to get through a bruising GOP Senate primary.

She appeared to have trouble courting the state's younger and more diverse voters in the general election.

Subscribe to CNBC on YouTube.