WASHINGTON, April 27 (Reuters) - Former U.S. Vice President Mike Pence appeared before a grand jury investigating former President Donald Trump's role in efforts to overturn the 2020 election, a source familiar with the matter told Reuters on Thursday.

Pence was inside U.S. District Court in Washington for more than seven hours, ABC News and NBC News reported earlier. Representatives for Pence had no comment.

The former vice president's appearance before the grand jury comes as he is exploring a possible challenge to Trump for the Republican presidential nomination in 2024.

Security was beefed up at the federal courthouse in Washington and a bomb-sniffing dog was spotted in the hallway.

Trump, who announced late last year his bid for the White House for 2024, was recently indicted in a separate probe in New York over alleged hush payments.

On Wednesday, Trump lost an appeal to block Pence from testifying in the special counsel probe, according to CNN.

Earlier this month, Pence disclosed that he would not appeal a judge's ruling that required him to testify to the federal grand jury about conversations he had with Trump leading up to the deadly attack on the U.S. Capitol on Jan. 6, 2021.

Special Counsel Jack Smith took over the probe into efforts to overturn the results of the 2020 presidential election, including a plot to submit phony slates of electors to block Congress from certifying Democrat Joe Biden's victory.

Ahead of the 2021 Capitol attacks by Trump supporters, the then-president repeatedly lambasted Pence for refusing to try to prevent Congress from certifying Biden’s win in the 2020 election.

Trump is also facing other legal hurdles as well, including a separate special counsel probe into his handling of classified documents and a probe in Georgia related to alleged interference with the state's 2020 election.