Egypt's border guards on Friday foiled an attempt by 22 Egyptians to cross to neighboring Libya through the western gate of Salloum City, state news agency MENA reported.
The group was arrested and the prosecution is investigating the incident.
Before the downfall of Libya's dictator Moammar Gaddafi in 2011 and the civil war that followed, hundreds of thousands of Egyptians used to travel to the oil-rich North African country for work.
The situation in Libya has only been worsening, with militias fighting each other and two rival governments jostling for power.
In February, the Islamic State group in Libya beheaded 20 Coptic Egyptian migrant workers.
Egypt responded with airstrikes on IS militant hideouts and has since been evacuating its nationals and warning them from travelling to the war-torn country.
However, illegal migration remains a prevailing problem as thousands of people seeking a better life die on their journey from Libya to Italy across the Mediterranean.
In April, at least 800 died following the capsizing of an overcrowded fishing boat carrying illegal migrants off the Libyan shore.