Deputy Health and Human Services Secretary Alex Azar meets reporters at the HHS Department in Washington, Thursday, June 8, 2006 to announce the approval of Gardasil, the first vaccine developed to protect women against cervical cancer.  (AP Photo/Evan Vucci)
EVAN VUCCI/ASSOCIATED PRESS
Deputy Health and Human Services Secretary Alex Azar meets reporters at the HHS Department in Washington, Thursday, June 8, 2006 to announce the approval of Gardasil, the first vaccine developed to protect women against cervical cancer. (AP Photo/Evan Vucci)
Now playing
01:52
Who is Alex Azar?
Fox News/Twitter
Now playing
01:33
ADL wants Fox News to fire Tucker Carlson over racist comments
CNN
Now playing
02:36
The truth behind Covid-19 vaccines for sale on the dark web
Now playing
04:22
Levi's CEO has message for Mitch McConnell
Now playing
01:54
'You think I'm racist': Former Fox News host storms off camera
Korie Robertson and Willie Robertson of the reality series "Duck Dynasty" attend the Capitol File 58th Presidential Inauguration Reception at Fiola Mare on January 19, 2017 in Washington, DC.
Paul Morigi/Getty Images
Korie Robertson and Willie Robertson of the reality series "Duck Dynasty" attend the Capitol File 58th Presidential Inauguration Reception at Fiola Mare on January 19, 2017 in Washington, DC.
Now playing
01:46
'Duck Dynasty' stars discuss raising biracial son on new show
FOX/"The Masked Singer"
Now playing
01:24
Nick Cannon makes big splash in 'Masked Singer' return
The Drew Barrymore Show/YouTube
Now playing
01:26
'Mom' star speaks out about not having kids in real life
Heinz ketchup packets are shown in New York on Monday, August 22, 2005. H.J. Heinz Co., the world's biggest ketchup maker, said first-quarter profit fell 19 percent on expenses to cut jobs and sell businesses.  (Photo by Andrew Harrer/Bloomberg via Getty Images)
Andrew Harrer/Bloomberg/Getty Images
Heinz ketchup packets are shown in New York on Monday, August 22, 2005. H.J. Heinz Co., the world's biggest ketchup maker, said first-quarter profit fell 19 percent on expenses to cut jobs and sell businesses. (Photo by Andrew Harrer/Bloomberg via Getty Images)
Now playing
01:53
Restaurants face a nationwide ketchup packet shortage
Camerota Berman both
CNN
Camerota Berman both
Now playing
02:33
CNN anchor Alisyn Camerota gets surprise tribute from co-anchor
Citigroup Chairman Richard Parsons delivers remarks on the US economy at the New York State Bar Association meetings in New York, January 28, 2009. Troubled US banking giant Citigroup last week named Parsons as its new chairman, the longtime top executive at media giant Time Warner, to steer it through its most challenging period.  AFP PHOTO / Emmanuel Dunand (Photo credit should read EMMANUEL DUNAND/AFP via Getty Images)
EMMANUEL DUNAND/AFP/AFP via Getty Images
Citigroup Chairman Richard Parsons delivers remarks on the US economy at the New York State Bar Association meetings in New York, January 28, 2009. Troubled US banking giant Citigroup last week named Parsons as its new chairman, the longtime top executive at media giant Time Warner, to steer it through its most challenging period. AFP PHOTO / Emmanuel Dunand (Photo credit should read EMMANUEL DUNAND/AFP via Getty Images)
Now playing
02:47
Dick Parsons: Georgia law is a bald-faced attempt to suppress Black vote
Courtesy of Warner Bros. Picture
Now playing
02:54
'Godzilla vs. Kong' is a pandemic box office hit
Now playing
01:30
5 ways to cut your plastic waste
CNN/Getty Images
Now playing
04:40
Stelter: After elevating Gaetz, Fox News barely covering scandal
NASA/Goddard/University of Arizona
Now playing
01:08
See NASA spacecraft successfully land on an asteroid
Now playing
06:51
Alisyn Camerota's kids wish her good luck in new role on CNN
(CNN) —  

A federal judge in Washington state ruled Tuesday that the Department of Health and Human Services had illegally ended a federal grant program aimed at curbing teen pregnancy – the fourth federal judge to rule against the department’s decision.

Washington state’s King County, a recipient of one of 84 Teen Pregnancy Prevention Program grants, sued the department and Secretary Alex Azar in February. King County said the early termination of the grant – June 2018 instead of June 2020 – would cut $2 million in funding and “makes it impossible to complete a vital evaluation of” its sex education curriculum.

The lawsuit sought to block Azar’s department from stopping the funds and “to restrain federal officials from applying an ideological bias to deny science-based projects that have been rigorously vetted and already funded by Congress,” according to a news release from the time.

In his decision, US District Judge John Coughenour ruled that “HHS failed to articulate a satisfactory explanation for its decision to shorten King County’s project period,” saying it “exemplifies arbitrary and capricious agency action meriting reversal.”

The ruling vacates HHS’ decision to terminate King County’s grant and orders the agency to review and process the annual continuation application in a timely manner “as if HHS had not terminated King County’s grant award.”

“This ruling is such a relief, as we are so close to the finish line for completing this study and building an evidence base for sex education nationwide,” King County Public Health Director Patty Hayes said in a statement.

HHS did not immediately reply to CNN’s request for comment on the decision.

Last summer, the Trump administration decided to end grant funding for the Teen Pregnancy Prevention Program. In an August statement, the department said it was reviewing best approaches after evaluating the first round of programs.

“The poor evaluation results were the reason that the Trump Administration, in its FY 2018 budget proposal, did not recommend continued funding for the TPP program and HHS hit the pause button on it,” the statement said.

Coughenour is the fourth federal judge to rule against HHS over its decision to end the program. Judges in Baltimore, Washington, DC, and Spokane, Washington, have made similar rulings.

Many researchers, program directors and city health officials have argued against ending the grants prematurely. Members of the Big Cities Health Coalition, a coalition of health officials from the 28 largest cities in the US, wrote a joint letter to then-HHS Secretary Tom Price in August urging him to reconsider the decision to cut the project period and funds.

CNN’s Jacqueline Howard contributed to this report.