Updated

U.S. Secretary of State John Kerry has arrived in Afghanistan.

Having just visited Iraq, it is his second unannounced trip in two days to a country the U.S. hasn't stabilized despite years of military efforts and economic support. Kerry's schedule Saturday includes meetings with Afghanistan's rival leaders: President Ashraf Ghani and Chief Executive Abdullah Abdullah.

The challenges in Afghanistan mirror those in Iraq. The U.S. invaded both countries over a decade ago, hoping to install stable democracies. Neither has panned out.

Afghanistan's Taliban insurgency persists; Iraq is struggling with the Islamic State group.

Sectarian and personal rivalries threaten both governments. Security vacuums in each threaten the U.S.

And despite President Barack Obama's pledges to end both wars, American troops can't get out of either country.