President Trump announced Wednesday that he intends to nominate Kirstjen Nielsen, a cybersecurity expert and deputy White House chief of staff, to be Homeland Security secretary, a job left vacant when John F. Kelly departed to become White House chief of staff in July.

The White House, in a statement, described Nielsen as having "extensive professional experience in the areas of homeland security policy and strategy, cybersecurity, critical infrastructure, and emergency management."

Nielsen is a longtime Homeland Security Department official who served as Kelly's chief of staff when he was DHS secretary and accompanied him to the White House as his deputy. She also worked at the DHS during the George W. Bush administration and founded a consulting firm focused on risk and security management.

Other contenders for the Cabinet post included Tom Bossert, Trump's homeland security adviser, and Kevin McAleenan, the acting commissioner of U.S. Customs and Border Protection.

[Trump slow to replace John Kelly at DHS as immigration, security challenges continue]

Nielsen had one crucial advantage — the absolute trust and support of Kelly, to whom she grew close after volunteering to be a "sherpa" to him as he went through the confirmation process this year.

At the White House, as Kelly's enforcer, Nielsen quickly emerged as a controversial presence. Her detractors viewed her no-nonsense style as brusque and complained that she could be unresponsive as she worked with Kelly to streamline operations and instill discipline in a White House often lacking structure. But her allies and supporters said she was simply helping to professionalize the West Wing — the sort of necessary but thankless task that often leaves some staff members griping.

Nielsen will inherit a massive and important portfolio. The Department of Homeland Security is considered a critical agency on matters of counterterrorism and national security. It is the agency, for example, that informed states they had been targeted by Russian hackers during the 2016 election campaign, and it would be responsible for monitoring and preventing such incidents in the future.

But it also bears primary responsibility for immigration enforcement and border protection — top priorities in the Trump administration. The Federal Emergency Management Agency, which has been coordinating the government's response to several recent hurricanes, the Secret Service, which protects the president and his family, and the Transportation Security Administration, which handles airport and other transportation-related security, are also a part of the DHS.

Nielsen is likely to have to navigate no shortage of controversies. Homeland Security officials will play a key role in implementing Trump's new entry ban, which is scheduled to fully take effect Oct. 18, and agency officials are also at the center of the president's decision to wind down DACA — the Deferred Action for Childhood Arrivals program — which allowed undocumented immigrants who were brought to the United States as children to avoid deportation.

The DHS, along with the Justice Department, has been energetic in implementing Trump's promised crackdown on illegal immigration — employing aggressive, controversial tactics such as arresting people suspected of being in the country illegally while they were in court seeking redress on matters including domestic violence complaints. Immigration agents have made 43 percent more arrests since Trump took office than in the same time period last year, but fewer deportations have taken place than in the comparable period last year.

Nielsen is not expected to face a difficult confirmation process in the Senate. She is widely viewed as a competent, experienced and nonpartisan security professional.

Given that polarizing and ideological figures such as former Milwaukee County sheriff David A. Clarke Jr. and Kansas Secretary of State Kris Kobach were previously rumored to be in the running for the DHS job, mostly for their hard-line views on immigration, the Nielsen choice would be more evidence of Kelly's ability to consolidate control and move the administration in a more conventional, mainstream direction.

Some of the president's senior advisers, including Stephen Miller, were said to favor an immigration hard-liner who would excite Trump's base.

But the Nielsen pick would preserve the DHS's reputation as an agency whose core mission is counterterrorism and national security.

Democrats and critics of the president said they were looking for a nominee with counterterrorism experience and a familiarity with DHS operations, and Nielsen would qualify on both counts.

"Nielsen's nomination is a strong signal of competence and experience being valued by the White House over ideologues and outsiders," said Stewart Verdery, a Republican lobbyist who worked in the department during the George W. Bush administration. "The homeland mission requires an unusual, diverse set of skills, and she has expertise in almost all of them."

Former Pennsylvania Gov. Tom Ridge (R), the first secretary of homeland security, said in a statement that Nielsen was a "homeland security veteran" who was "extremely well versed in the all-hazard threats" challenging the nation's security and resilience.

"Kirstjen can hit the ground running and there won't be a learning curve," Ridge said. "Most importantly, in this hyper-political environment, Kirstjen is not a self-promoter. She is a patriot and takes a mission-focused approach to her work."

Nick Miroff and Maria Sacchetti contributed to this report.