(Reference for a preliminary ruling – Area of freedom, security and justice – Border control, asylum and immigration – Regulation (EU) 2016/399 – Article 32 – Temporary reintroduction of border control by a Member State at its internal borders – Article 14 – Refusal of entry – Equation of internal borders with external borders – Directive 2008/115/EC – Scope – Article 2(2)(a))
In Case C‑143/22,
REQUEST for a preliminary ruling under Article 267 TFEU from the Conseil d’État (Council of State, France), made by decision of 24 February 2022, received at the Court on 1 March 2022, in the proceedings
Association Avocats pour la défense des droits des étrangers (ADDE),
Association nationale d’assistance aux frontières pour les étrangers (ANAFE),
Association de recherche, de communication et d’action pour l’accès aux traitements (ARCAT),
Comité inter-mouvements auprès des évacués (Cimade),
Fédération des associations de solidarité avec tou.te.s les immigré.e.s (FASTI),
Groupe d’information et de soutien des immigré.e.s (GISTI),
Ligue des droits de l’homme (LDH),
Le paria,
Syndicat des avocats de France (SAF),
SOS – Hépatites Fédération
v
Ministre de l’Intérieur,
intervening party :
Défenseur des droits,
THE COURT (Fourth Chamber),
composed of C. Lycourgos (Rapporteur), President of the Chamber, L.S. Rossi, J.-C. Bonichot, S. Rodin and O. Spineanu-Matei, Judges,
Advocate General : A. Rantos,
Registrar : M. Krausenböck, Administrator,
having regard to the written procedure and further to the hearing on 19 January 2023,
after considering the observations submitted on behalf of :
– Association Avocats pour la défense des droits des étrangers (ADDE), Association nationale d’assistance aux frontières pour les étrangers (ANAFE), Association de recherche, de communication et d’action pour l’accès aux traitements (ARCAT), Comité inter-mouvements auprès des évacués (Cimade), Fédération des associations de solidarité avec tou.te.s les immigré.e.s (FASTI), Groupe d’information et de soutien des immigré.e.s (GISTI), Ligue des droits de l’homme (LDH), Le paria, Syndicat des avocats de France (SAF) and SOS – Hépatites Fédération, by P. Spinosi, lawyer,
– the Défenseur des droits, by C. Hédon, Défenseure des droits, M. Cauvin and A. Guitton, acting as advisers, and by I. Zribi, lawyer,
– the French Government, by A.-L. Desjonquères and J. Illouz, acting as Agents,
– the Polish Government, by B. Majczyna, E. Borawska-Kędzierska and A. Siwek-Ślusarek, acting as Agents,
– the European Commission, by A. Azéma, A. Katsimerou, T. Lilamand and J. Tomkin, acting as Agents,
after hearing the Opinion of the Advocate General at the sitting on 30 March 2023,
gives the following
Judgment
1 This request for a preliminary ruling concerns the interpretation of Article 14 of Regulation (EU) 2016/399 of the European Parliament and of the Council of 9 March 2016 on a Union Code on the rules governing the movement of persons across borders (Schengen Borders Code) (OJ 2016 L 77, p. 1, ‘the Schengen Borders Code’), and of Directive 2008/115/EC of the European Parliament and of the Council of 16 December 2008 on common standards and procedures in Member States for returning illegally staying third-country nationals (OJ 2008 L 348, p. 98).
2 The request has been made in proceedings between Association Avocats pour la défense des droits des étrangers (ADDE), Association nationale d’assistance aux frontières pour les étrangers (ANAFE), Association de recherche, de communication et d’action pour l’accès aux traitements (ARCAT), Comité inter-mouvements auprès des évacués (Cimade), Fédération des associations de solidarité avec tou.te.s les immigré.e.s (FASTI), Groupe d’information et de soutien des immigré.e.s (GISTI), Ligue des droits de l’homme (LDH), Le Paria, Syndicat des avocats de France (SAF), SOS – Hépatites Fédération, and Ministre de l’Intérieur (Minister of the Interior, France) regarding the legality of the ordonnance no 2020-1733 du 16 décembre 2020 portant partie législative du code de l’entrée et du séjour des étrangers et du droit d’asile (Order No 2020-1733 of 16 December 2020, laying down the legislative part of the Code on Entry and Residence of Foreigners and the Right of Asylum) (JORF of 30 December 2020, Text No 41).
Legal context
European Union law
The Schengen Borders Code
3 Pursuant to Article 2 of the Schengen Borders Code :
‘For the purposes of this Regulation the following definitions apply :
1. “internal borders” means :
(a) the common land borders, including river and lake borders, of the Member States ;
(b) the airports of the Member States for internal flights ;
(c) sea, river and lake ports of the Member States for regular internal ferry connections ;
2. “external borders” means : the Member States’ land borders, including river and lake borders, sea borders and their airports, river ports, sea ports and lake ports, provided that they are not internal borders ;
…’
4 Title II of that code, which concerns ‘External Borders’, includes Articles 5 to 21.
5 Article 14 of the code, entitled ‘Refusal of entry’, states :
‘1. A third-country national who does not fulfil all the entry conditions laid down in Article 6(1) and does not belong to the categories of persons referred to in Article 6(5) shall be refused entry to the territories of the Member States. This shall be without prejudice to the application of special provisions concerning the right of asylum and to international protection or the issue of long-stay visas.
2. Entry may only be refused by a substantiated decision stating the precise reasons for the refusal. The decision shall be taken by an authority empowered by national law. It shall take effect immediately.
The substantiated decision stating the precise reasons for the refusal shall be given by means of a standard form, as set out in Annex V, Part B, filled in by the authority empowered by national law to refuse entry. The completed standard form shall be handed to the third-country national concerned, who shall acknowledge receipt of the decision to refuse entry by means of that form.
Data on third-country nationals whose entry for a short stay has been refused shall be registered in the EES in accordance with Article 6a(2) of this Regulation and Article 18 of Regulation (EU) 2017/2226 [of the European Parliament and of the Council of 30 November 2017 establishing an Entry/Exit System (EES) to register entry and exit data and refusal of entry data of third-country nationals crossing the external borders of the Member States and determining the conditions for access to the EES for law enforcement purposes, and amending the Convention implementing the Schengen Agreement and Regulations (EC) No 767/2008 and (EU) No 1077/2011 (OJ 2017 L 327, p. 20)].
3. Persons refused entry shall have the right to appeal. Appeals shall be conducted in accordance with national law. A written indication of contact points able to provide information on representatives competent to act on behalf of the third-country national in accordance with national law shall also be given to the third-country national.
Lodging such an appeal shall not have suspensive effect on a decision to refuse entry.
Without prejudice to any compensation granted in accordance with national law, the third-country national concerned shall, where the appeal concludes that the decision to refuse entry was ill-founded, be entitled to the correction of the data entered in the EES or of the cancelled entry stamp, or both, and any other cancellations or additions which have been made, by the Member State which refused entry.
4. The border guards shall ensure that a third-country national refused entry does not enter the territory of the Member State concerned.
5. Member States shall collect statistics on the number of persons refused entry, the grounds for refusal, the nationality of the persons who were refused entry and the type of border (land, air or sea) at which they were refused entry and submit them yearly to the Commission (Eurostat) in accordance with Regulation (EC) No 862/2007 of the European Parliament and of the Council [of 11 July 2007 on Community statistics on migration and international protection and repealing Council Regulation (EEC) No 311/76 on the compilation of statistics on foreign workers (OJ 2007 L 199, p. 23)].
6. Detailed rules governing refusal of entry are given in Part A of Annex V.’
6 Title III of the Schengen Borders Code, which concerns ‘Internal Borders’, includes Articles 22 to 35.
7 Article 25 of that code, entitled ‘General framework for the temporary reintroduction of border control at internal borders’, provides :
‘Where, in the area without internal border control, there is a serious threat to public policy or internal security in a Member State, that Member State may exceptionally reintroduce border control at all or specific parts of its internal borders for a limited period of up to 30 days or for the foreseeable duration of the serious threat if its duration exceeds 30 days. The scope and duration of the temporary reintroduction of border control at internal borders shall not exceed what is strictly necessary to respond to the serious threat.’
8 Article 32 of the Schengen Borders Code, entitled ‘Provisions to be applied where border control is reintroduced at internal borders’, provides :
‘Where border control at internal borders is reintroduced, the relevant provisions of Title II shall apply mutatis mutandis.’
9 Annex V, Part A, of the Schengen Borders Code provides :
‘1. When refusing entry, the competent border guard shall :
(a) fill in the standard form for refusing entry, as shown in Part B. The third-country national concerned shall sign the form and shall be given a copy of the signed form. Where the third-country national refuses to sign, the border guard shall indicate this refusal in the form under the section “comments” ;
(b) for third-country nationals whose entry for a short stay has been refused, register in the EES the data on refusal of entry in accordance with Article 6a(2) of this Regulation and Article 18 of Regulation (EU) 2017/2226 ;
(c) annul or revoke the visas, as appropriate, in accordance with the conditions laid down in Article 34 of Regulation (EC) No 810/2009 [of the European Parliament and of the Council of 13 July 2009 establishing a Community Code on Visas (Visa Code) (OJ 2009 L 243, p. 1)] ;
(d) for third-country nationals whose refusals of entry are not to be registered into the EES, affix an entry stamp on the passport, cancelled by a cross in indelible black ink, and write opposite it on the right-hand side, also in indelible ink, the letter(s) corresponding to the reason(s) for refusing entry, the list of which is given on the standard form for refusing entry as shown in Part B of this Annex. In addition, for these categories of persons, the border guard shall record every refusal of entry in a register or on a list stating the identity and nationality of the third-country national concerned, the references of the document authorising the third-country national to cross the border and the reason for, and date of, refusal of entry.
The practical arrangements for stamping are set out in Annex IV.
2. If a third-country national who has been refused entry is brought to the border by a carrier, the authority responsible locally shall :
(a) order the carrier to take charge of the third-country national and transport him or her without delay to the third country from which he or she was brought, to the third country which issued the document authorising him or her to cross the border, or to any other third country where he or she is guaranteed admittance, or to find means of onward transportation in accordance with Article 26 of the Schengen Convention and Council Directive 2001/51/EC [of 28 June 2001 supplementing the provisions of Article 26 of the Convention implementing the Schengen Agreement of 14 June 1985 (OJ 2001 L 187, p. 45)] ;
(b) pending onward transportation, take appropriate measures, in compliance with national law and having regard to local circumstances, to prevent third-country nationals who have been refused entry from entering illegally.
…’
10 Pursuant to Article 44 of that code, entitled ‘Repeal’ :
‘Regulation (EC) No 562/2006 [of the European Parliament and of the Council of 15 March 2006 establishing a Community Code on the rules governing the movement of persons across borders (Schengen Borders Code) (OJ 2006 L 105, p. 1)] is repealed.
References to the repealed Regulation shall be construed as references to this Regulation and shall be read in accordance with the correlation table in Annex X.’
11 In accordance with that correlation table, Article 14 of the Schengen Borders Code corresponds to Article 13 of Regulation No 562/2006.
Directive 2008/115
12 Article 2(1) and (2) of Directive 2008/115 states :
‘1. This Directive applies to third-country nationals staying illegally on the territory of a Member State.
2. Member States may decide not to apply this Directive to third-country nationals who :
(a) are subject to a refusal of entry in accordance with Article 13 of [Regulation No 562/2006], or who are apprehended or intercepted by the competent authorities in connection with the irregular crossing by land, sea or air of the external border of a Member State and who have not subsequently obtained an authorisation or a right to stay in that Member State ;
(b) are subject to return as a criminal law sanction or as a consequence of a criminal law sanction, according to national law, or who are the subject of extradition procedures.’
13 Article 3 of that directive provides :
‘For the purpose of this Directive the following definitions shall apply :
…
2. “illegal stay” means the presence on the territory of a Member State, of a third-country national who does not fulfil, or no longer fulfils the conditions of entry as set out in Article 5 of [Regulation No 562/2006] or other conditions for entry, stay or residence in that Member State ;
3. “return” means the process of a third-country national going back – whether in voluntary compliance with an obligation to return, or enforced – to :
– his or her country of origin, or
– a country of transit in accordance with Community or bilateral readmission agreements or other arrangements, or
– another third country, to which the third-country national concerned voluntarily decides to return and in which he or she will be accepted ;
…’
14 Article 4(4) of the directive provides :
‘With regard to third-country nationals excluded from the scope of this Directive in accordance with Article 2(2)(a), Member States shall :
(a) ensure that their treatment and level of protection are no less favourable than as set out in Article 8(4) and (5) (limitations on use of coercive measures), Article 9(2)(a) (postponement of removal), Article 14(1)(b) and (d) (emergency health care and taking into account needs of vulnerable persons), and Articles 16 and 17 (detention conditions) and
(b) respect the principle of non-refoulement.’
15 Article 5 of Directive 2008/115 provides :
‘When implementing this Directive, Member States shall take due account of :
(a) the best interests of the child ;
(b) family life ;
(c) the state of health of the third-country national concerned,
and respect the principle of non-refoulement.’
16 Article 6 of that directive provides :
‘1. Member States shall issue a return decision to any third-country national staying illegally on their territory, without prejudice to the exceptions referred to in paragraphs 2 to 5.
2. Third-country nationals staying illegally on the territory of a Member State and holding a valid residence permit or other authorisation offering a right to stay issued by another Member State shall be required to go to the territory of that other Member State immediately. In the event of non-compliance by the third-country national concerned with this requirement, or where the third-country national’s immediate departure is required for reasons of public policy or national security, paragraph 1 shall apply.
3. Member States may refrain from issuing a return decision to a third-country national staying illegally on their territory if the third-country national concerned is taken back by another Member State under bilateral agreements or arrangements existing on the date of entry into force of this Directive. In such a case the Member State which has taken back the third-country national concerned shall apply paragraph 1.
…’
17 The first subparagraph of Article 7(1) of that directive provides :
‘A return decision shall provide for an appropriate period for voluntary departure of between seven and thirty days, without prejudice to the exceptions referred to in paragraphs 2 and 4. Member States may provide in their national legislation that such a period shall be granted only following an application by the third-country national concerned. In such a case, Member States shall inform the third-country nationals concerned of the possibility of submitting such an application.’
18 Article 15(1) of that directive provides :
‘Unless other sufficient but less coercive measures can be applied effectively in a specific case, Member States may only keep in detention a third-country national who is the subject of return procedures in order to prepare the return and/or carry out the removal process, in particular when :
(a) there is a risk of absconding or
(b) the third-country national concerned avoids or hampers the preparation of return or the removal process.
Any detention shall be for as short a period as possible and only maintained as long as removal arrangements are in progress and executed with due diligence.’
French law
19 Article L. 213-3-1 of the Code de l’entrée et du séjour des étrangers et du droit d’asile (Code on the Entry and Residence of Foreigners and the Right of Asylum), in the version resulting from the loi no 2018-778, du 10 septembre 2018, pour une immigration maîtrisée, un droit d’asile effectif et une intégration réussie (Law No 2018-778 of 10 September 2018 for controlled immigration, an effective right of asylum and successful integration) (JORF of 11 September 2018, Text No 1) (‘the former Ceseda’), stated :
‘In the event of the temporary reintroduction of border control at internal borders provided for in Chapter II of Title III of the [Schengen Borders Code], the decisions referred to in Article L. 213-2 may be taken in respect of foreign nationals who have arrived directly from the territory of a State party to the Schengen Convention signed on 19 June 1990, who have entered the territory of Metropolitan France crossing an internal land border without being authorised to do so and were checked in an area between the border and a line drawn 10 kilometres behind it. The procedures for these checks are defined by decree in the Conseil d’État [(Council of State, France)].’
20 Order No 2020-1733 recast the legislative part of the Code on the Entry and Residence of Foreigners and the Right of Asylum. Article L. 332-2 of that code, as amended (‘the amended Ceseda’) provides :
‘The decision refusing entry, which shall be in writing and substantiated, shall be taken by an officer belonging to a category prescribed by regulations.
The notification of the decision refusing entry shall state that the foreign national has the right to inform, or cause to be informed, the person he or she has indicated that he or she intended to visit, his or her consulate or the adviser of his or her choice. It shall state that the foreign national has the right to refuse to be repatriated before one clear day has passed, under the conditions laid down in Article L. 333-2.
The decision and the notification of rights which accompanies it shall be provided to him in a language he or she understands.
Particular attention shall be paid to vulnerable persons, especially minors whether accompanied by an adult or not.’
21 Article L. 332-3 of the amended Ceseda provides :
‘The procedure laid down in Article L. 332-2 is applicable to the decision to refuse entry taken against the foreign national pursuant to Article 6 of the [Schengen Borders Code]. It shall also apply to checks carried out at an internal border in the event of the temporary reintroduction of checks at internal borders under the conditions laid down in Chapter II of Title III of the [Schengen Borders Code].’
The dispute in the main proceedings and the question referred for a preliminary ruling
22 The associations referred to in paragraph 2 of the present judgment are challenging the validity of Order No 2020-1733 before the Conseil d’État (Council of State), in an action for annulment of that order, on the grounds, inter alia, that Article L. 332-3 of the amended Ceseda resulting from it infringes Directive 2008/115 in that it allows decisions to refuse entry at internal borders where checks have been reintroduced.
23 The referring court observes that the Court held, in its judgment of 19 March 2019, Arib and Others (C‑444/17, EU:C:2019:220), that Article 2(2)(a) of Directive 2008/115, read in conjunction with Article 32 of the Schengen Borders Code, does not apply to the situation of an illegally staying third-country national who was apprehended in the immediate vicinity of an internal border of a Member State, even where that Member State has reintroduced border control at that border, pursuant to Article 25 of that code, on account of a serious threat to public policy or to internal security in that Member State.
24 The Conseil d’État (Council of State) points out that, in its Decision No 428175 of 27 November 2020, it held that the provisions of Article L. 213-3-1 of the former Ceseda, which provided that in the event of the temporary reintroduction of border control at internal borders, a foreign national arriving directly from the territory of a State party to the Convention implementing the Schengen Agreement of 14 June 1985 between the Governments of the States of the Benelux Economic Union, the Federal Republic of Germany and the French Republic on the gradual abolition of checks at their common borders, signed in Schengen on 19 June 1990 and which entered into force on 26 March 1995 (OJ 2000 L 239, p. 19, ‘the Schengen Convention’), could be refused entry under the terms of Article L. 213-2 of the former Ceseda if he or entered the territory of Metropolitan France crossing an internal land border without being authorised to do so and was checked in an area between the border and a line drawn 10 kilometres inside that border, were contrary to Directive 2008/115.
25 Admittedly, according to the Conseil d’État (Council of State), Article L. 332-3 of the amended Ceseda does not repeat the provisions of Article L. 213-3-1 of the former Ceseda. However, Article L. 332-3 of the amended Ceseda again provides only for the adoption of a refusal of entry while carrying out border checks at internal borders in the event of the temporary reintroduction of border control at internal borders under the conditions laid down in Chapter II of Title III of the Schengen Borders Code.
26 That court therefore considers it necessary to determine whether, in such a case, a third-country national arriving directly from the territory of a State party to the Schengen Convention who presents themselves at an authorised stationary or mobile border crossing point, without being in possession of documents justifying an authorisation to enter or right to stay in France, may be refused entry on the basis of Article 14 of the Schengen Borders Code, without Directive 2008/115 being applicable.
27 In those circumstances, the Conseil d’État (Council of State) decided to stay the proceedings and to refer the following question to the Court of Justice for a preliminary ruling :
‘In the event of the temporary reintroduction of border controls at internal borders, under the conditions laid down in Chapter II of Title III of [the Schengen Borders Code], can foreign nationals arriving directly from the territory of a State party to the Schengen Convention … be refused entry, when entry checks are carried out at that border, on the basis of Article 14 of that [code], without [Directive 2008/115] being applicable ?’
Consideration of the question referred
28 By its question referred for a preliminary ruling, the national court asks, in essence, whether the Schengen Borders Code and Directive 2008/115 must be interpreted as meaning that, where a Member State has reintroduced checks at its internal borders, it may adopt, in respect of a third-country national who presents himself or herself at an authorised border crossing point where such checks are carried out, a decision refusing entry, within the meaning of Article 14 of that code, without being subject to compliance with that directive.
29 Article 25 of the Schengen Borders Code allows, exceptionally and under certain conditions, a Member State to reintroduce temporarily border control at all or specific parts of its internal borders where there is a serious threat to public policy or internal security in that Member State. Under Article 32 of the code, where border control at internal borders is reintroduced, the relevant provisions of the Title II of the code relating to external borders shall apply mutatis mutandis.
30 That is the case with Article 14 of the Schengen Borders Code, which provides that a third-country national who does not fulfil all the entry conditions laid down in Article 6(1) and does not belong to the categories of persons referred to in Article 6(5) shall be refused entry to the territories of the Member States.
31 However, it is important to remember that a third-country national who, after entering the territory of a Member State illegally is present on that territory without fulfilling the conditions for entry, stay or residence is, therefore, staying illegally, within the meaning of Directive 2008/115. Under Article 2(1) of that directive, and without prejudice to Article 2(2) of the directive, that third-country national falls within the scope of the directive, without his or her presence in the territory of the Member State concerned being subject to a condition as to minimum duration or intention to remain in that territory. He or she must therefore, in principle, be subject to the common standards and procedures laid down by the directive for the purpose of his or her removal, as long as his or her stay has not, as the case may be, been regularised (see, to that effect, judgment of 19 March 2019, Arib and Others, C‑444/17, EU:C:2019:220, paragraphs 37 and 39 and the case-law cited).
32 This also applies where the third-country national has been apprehended at a border crossing point, provided that the border crossing point is on the territory of that Member State. In that respect, it should be noted that a person may have entered the territory of a Member State even before crossing a border crossing point (see, by analogy, judgment of 5 February 2020, Staatssecretaris van Justitie en Veiligheid (Signing-on of seamen in the port of Rotterdam), C‑341/18, EU:C:2020:76, paragraph 45).
33 It should also be specified, by way of example, that when checks are carried out on board a train between the time when the train leaves the last station located on the territory of a Member State sharing an internal border with a Member State that has reintroduced checks at its internal borders, and the moment when that train enters the first station situated on the territory of the latter Member State, the check on board that same train must, unless otherwise agreed between those two Member States, be regarded as a check carried out at a border crossing point situated on the territory of the Member State which has reintroduced such checks. A third-country national who has been checked on board this train will necessarily remain on the territory of the latter Member State following the check, within the meaning of Article 2(1) of Directive 2008/115.
34 However, it should also be noted that Article 2(2) of Directive 2008/115 allows Member States to exclude, exceptionally and under certain conditions, third-country nationals who are staying illegally on their territory from the scope of that directive.
35 Thus, on the one hand, Article 2(2)(a) of Directive 2008/115 allows Member States not to apply that directive, subject to the provisions of Article 4(4) thereof, in two specific situations, namely that of third-country nationals who are the subject to a refusal of entry at an external border of a Member State, in accordance with Article 14 of the Schengen Borders Code, or that of third-country nationals who are apprehended or intercepted in connection with the irregular crossing of such an external border and who have not subsequently obtained authorisation or a right to reside in that Member State.
36 However, it is clear from the Court’s case-law that those two situations relate exclusively to the crossing of an external border of a Member State, as defined in Article 2 of the Schengen Borders Code, and do not therefore concern the crossing of a border common to Member States forming part of the Schengen area, even where checks have been reintroduced at that border, pursuant to Article 25 of that code, on account of a serious threat to public policy or the internal security of that Member State (see, to that effect, judgment of 19 March 2019, Arib and Others, C‑444/17, EU:C:2019:220, paragraphs 45 and 67).
37 It follows, as the Advocate General pointed out in point 35 of his Opinion, that Article 2(2)(a) of Directive 2008/115 does not authorise a Member State which has reintroduced checks at its internal borders to derogate from the common standards and procedures laid down by that directive in order to remove a third-country national who has been intercepted, without a valid residence permit, at one of the border crossing points situated in the territory of that Member State where such checks are carried out.
38 On the other hand, although Article 2(2)(b) of Directive 2008/115 authorises Member States not to apply that directive to third-country nationals who are subject to a criminal penalty providing for or resulting in their return, in accordance with national law, or who are subject to extradition proceedings, it must be noted that such a case is not the one referred to by the provision at issue in the main proceedings.
39 It follows from the foregoing, first, that a Member State which has reintroduced checks at its internal borders may apply, mutatis mutandis, Article 14 of the Schengen Borders Code and paragraph 1 of Part A of Annex V to that code in respect of a third-country national who is intercepted, without a legal residence permit, at an authorised border crossing point where such checks are carried out.
40 On the other hand, where the border crossing point is located on the territory of the Member State concerned, the latter must ensure that the consequences of such application, mutatis mutandis, of the provisions referred to in the previous point do not result in disregard of the common standards and procedures laid down in Directive 2008/115. The fact that this obligation on the Member State concerned is likely to render ineffective to a large extent any decision to refuse entry to a third-country national arriving at one of its internal borders is not such as to alter that finding.
41 With regard to the relevant provisions of that directive, it should be recalled, in particular, that it follows from Article 6(1) of Directive 2008/115 that any third-country national staying illegally on the territory of a Member State must, without prejudice to the exceptions provided for in paragraphs 2 to 5 of that article and in strict compliance with the requirements laid down in Article 5 of that directive, be the subject of a return decision, which must identify, among the third countries referred to in Article 3(3) of that directive, the country to which he or she must return (judgment of 22 November 2022, Staatssecretaris van Justitie en Veiligheid (Removal – Medicinal cannabis), C‑69/21, EU:C:2022:913, paragraph 53).
42 In addition, a third-country national who is the subject of such a return decision must still, in principle, be given, under Article 7 of Directive 2008/115, a certain period of time in which to leave the territory of the Member State concerned voluntarily. Forced removal is to take place only as a last resort, in accordance with Article 8 of that directive, and subject to Article 9 thereof, which requires Member States to postpone removal in the cases it sets out (judgment of 17 December 2020, Commission v Hungary (Reception of applicants for international protection), C‑808/18, EU:C:2020:1029, paragraph 252).
43 Furthermore, it follows from Article 15 of Directive 2008/115 that the detention of an illegally staying third-country national may only be imposed in certain specific cases. However, as the Advocate General pointed out, in essence, in point 46 of his Opinion, that article does not preclude a national from being detained, pending his or her removal, where he or she represents a genuine, present and sufficiently serious threat to public policy or domestic security, provided that such detention complies with the conditions set out in Articles 15 to 18 of that directive (see, to that effect, judgment of 2 July 2020, Stadt Frankfurt am Main, C‑18/19, EU:C:2020:511, paragraphs 41 to 48).
44 Furthermore, Directive 2008/115 does not rule out the possibility for Member States to impose a prison sentence for offences other than those relating solely to illegal entry, including in situations where the return procedure established by that directive has not yet been completed. Consequently, that directive also does not preclude the arrest or placing in police custody of an illegally staying third-country national where such measures are adopted on the ground that that national is suspected of having committed an offence other than simply entering the national territory illegally, and in particular an offence likely to threaten public policy or the internal security of the Member State concerned (judgment of 19 March 2019, Arib and Others, C‑444/17, EU:C:2019:220, paragraph 66).
45 It follows that, contrary to what the French Government maintains, the application, in a case such as that referred to in the reference for a preliminary ruling, of the common standards and procedures laid down by Directive 2008/115 is not such as to make it impossible to maintain public order and safeguard internal security within the meaning of Article 72 TFEU.
46 In light of all the foregoing considerations, the answer to the question referred for a preliminary ruling is that the Schengen Borders Code and Directive 2008/115 must be interpreted as meaning that, where a Member State has reintroduced controls at its internal borders, it may adopt, in respect of a third-country national who presents himself or herself at an authorised border crossing point situated on its territory and where such controls are carried out, a decision refusing entry, by virtue of an application mutatis mutandis of Article 14 of that code, provided that the common standards and procedures laid down by that directive are applied to that national with a view to his or her removal.
Costs
47 Since these proceedings are, for the parties to the main proceedings, a step in the action pending before the national court, the decision on costs is a matter for that court. Costs incurred in submitting observations to the Court, other than the costs of those parties, are not recoverable.
On those grounds, the Court (Fourth Chamber) hereby rules :
Regulation (EU) 2016/399 of the European Parliament and of the Council of 9 March 2016 on a Union Code on the rules governing the movement of persons across borders (Schengen Borders Code) and Directive 2008/115/EC of the European Parliament and of the Council of 16 December 2008 on common standards and procedures in Member States for returning illegally staying third-country nationals,
must be interpreted as meaning that, where a Member State has reintroduced controls at its internal borders, it may adopt, in respect of a third-country national who presents himself or herself at an authorised border crossing point situated on its territory and where such controls are carried out, a decision refusing entry, by virtue of an application mutatis mutandis of Article 14 of that regulation, provided that the common standards and procedures laid down in that directive are applied to that national with a view to his or her removal.