(2) Speak to the Israelite people and say to them: When you enter the land that I give to you, the land shall observe a sabbath of the LORD.
(כה) אֵין שְׁבִיעִית נוֹהֶגֶת אֶלָּא בְּאֶרֶץ יִשְׂרָאֵל בִּלְבַד שֶׁנֶּאֱמַר (ויקרא כה ב) "כִּי תָבֹאוּ אֶל הָאָרֶץ" וְגוֹ'. וְנוֹהֶגֶת בֵּין בִּפְנֵי הַבַּיִת בֵּין שֶׁלֹּא בִּפְנֵי הַבַּיִת:
(25) The seventh year is only practiced in the Land of Israel exclusively, as it is stated (Leviticus 25:2), "When you come to the land, etc." And it is practiced both in the presence of the Temple and not in the presence of the Temple.
Ammon and Moab: Not part of the land

Source: Craig W. Tyson, 'The Religion of the Ammonites: A Specimen of Levantine Religion from the Iron Age II (ca. 1000–500 BCE)', Religions 2019, 10(3), 153
(ב) [ב] "כי תבאו...": יכול משבאו לעבר הירדן? תלמוד לומר "אל הארץ"-- ארץ המיוחדת. יכול משבאו לעמון ומואב? תלמוד לומר "אשר אני נותן לכם"-- ולא עמון ומואב.
(2) 2) (Vayikra 25:2) ("Speak to the children of Israel and say to them: When you come to the land that I give to you, the land shall rest a Sabbath to the L–rd.") "When you come": I might think (that this phrase subsumes) coming to Trans-Jordan; it is, therefore, written "to the land" — the specific land. I might think (that it subsumes) coming to Ammon and Moab; it is, therefore, written "that I give to you," and not to Ammon and Moab.
(9) And the LORD said to me: Do not harass the Moabites or provoke them to war. For I will not give you any of their land as a possession; I have assigned Ar as a possession to the descendants of Lot.—
(17) The LORD spoke to me, saying: (18) You are now passing through the territory of Moab, through Ar. (19) You will then be close to the Ammonites; do not harass them or start a fight with them. For I will not give any part of the land of the Ammonites to you as a possession; I have assigned it as a possession to the descendants of Lot.—
Ammon: Conquered?
(יז) וַיִּצָּֽעֲקוּ֙ בְּנֵ֣י עַמּ֔וֹן וַֽיַּחֲנ֖וּ בַּגִּלְעָ֑ד וַיֵּאָֽסְפוּ֙ בְּנֵ֣י יִשְׂרָאֵ֔ל וַֽיַּחֲנ֖וּ בַּמִּצְפָּֽה׃ (יח) וַיֹּאמְר֨וּ הָעָ֜ם שָׂרֵ֤י גִלְעָד֙ אִ֣ישׁ אֶל־רֵעֵ֔הוּ מִ֣י הָאִ֔ישׁ אֲשֶׁ֣ר יָחֵ֔ל לְהִלָּחֵ֖ם בִּבְנֵ֣י עַמּ֑וֹן יִֽהְיֶ֣ה לְרֹ֔אשׁ לְכֹ֖ל יֹשְׁבֵ֥י גִלְעָֽד׃ {פ}
(יב) וַיִּשְׁלַ֤ח יִפְתָּח֙ מַלְאָכִ֔ים אֶל־מֶ֥לֶךְ בְּנֵֽי־עַמּ֖וֹן לֵאמֹ֑ר מַה־לִּ֣י וָלָ֔ךְ כִּֽי־בָ֥אתָ אֵלַ֖י לְהִלָּחֵ֥ם בְּאַרְצִֽי׃ (יג) וַיֹּ֩אמֶר֩ מֶ֨לֶךְ בְּנֵֽי־עַמּ֜וֹן אֶל־מַלְאֲכֵ֣י יִפְתָּ֗ח כִּֽי־לָקַ֨ח יִשְׂרָאֵ֤ל אֶת־אַרְצִי֙ בַּעֲלוֹת֣וֹ מִמִּצְרַ֔יִם מֵאַרְנ֥וֹן וְעַד־הַיַּבֹּ֖ק וְעַד־הַיַּרְדֵּ֑ן וְעַתָּ֕ה הָשִׁ֥יבָה אֶתְהֶ֖ן בְּשָׁלֽוֹם׃ (יד) וַיּ֥וֹסֶף ע֖וֹד יִפְתָּ֑ח וַיִּשְׁלַח֙ מַלְאָכִ֔ים אֶל־מֶ֖לֶךְ בְּנֵ֥י עַמּֽוֹן׃ (טו) וַיֹּ֣אמֶר ל֔וֹ כֹּ֖ה אָמַ֣ר יִפְתָּ֑ח לֹֽא־לָקַ֤ח יִשְׂרָאֵל֙ אֶת־אֶ֣רֶץ מוֹאָ֔ב וְאֶת־אֶ֖רֶץ בְּנֵ֥י עַמּֽוֹן׃
(10) And the elders of Gilead answered Jephthah, “The LORD Himself shall be witness between us: we will do just as you have said.” (11) Jephthah went with the elders of Gilead, and the people made him their commander and chief. And Jephthah repeated all these terms before the LORD at Mizpah.
(12) Jephthah then sent messengers to the king of the Ammonites, saying, “What have you against me that you have come to make war on my country?” (13) The king of the Ammonites replied to Jephthah’s messengers, “When Israel came from Egypt, they seized the land which is mine, from the Arnon to the Jabbok as far as the Jordan. Now, then, restore it peaceably.” (14) Jephthah again sent messengers to the king of the Ammonites. (15) He said to him, “Thus said Jephthah: Israel did not seize the land of Moab or the land of the Ammonites.”
(כט) וַתְּהִ֤י עַל־יִפְתָּח֙ ר֣וּחַ יי וַיַּעֲבֹ֥ר אֶת־הַגִּלְעָ֖ד וְאֶת־מְנַשֶּׁ֑ה וַֽיַּעֲבֹר֙ אֶת־מִצְפֵּ֣ה גִלְעָ֔ד וּמִמִּצְפֵּ֣ה גִלְעָ֔ד עָבַ֖ר בְּנֵ֥י עַמּֽוֹן׃ (ל) וַיִּדַּ֨ר יִפְתָּ֥ח נֶ֛דֶר לַיי וַיֹּאמַ֑ר אִם־נָת֥וֹן תִּתֵּ֛ן אֶת־בְּנֵ֥י עַמּ֖וֹן בְּיָדִֽי׃ (לא) וְהָיָ֣ה הַיּוֹצֵ֗א אֲשֶׁ֨ר יֵצֵ֜א מִדַּלְתֵ֤י בֵיתִי֙ לִקְרָאתִ֔י בְּשׁוּבִ֥י בְשָׁל֖וֹם מִבְּנֵ֣י עַמּ֑וֹן וְהָיָה֙ לַיי וְהַעֲלִיתִ֖יהוּ עֹלָֽה׃ {פ}
(לב) וַיַּעֲבֹ֥ר יִפְתָּ֛ח אֶל־בְּנֵ֥י עַמּ֖וֹן לְהִלָּ֣חֶם בָּ֑ם וַיִּתְּנֵ֥ם יי בְּיָדֽוֹ׃ (לג) וַיַּכֵּ֡ם מֵעֲרוֹעֵר֩ וְעַד־בֹּאֲךָ֨ מִנִּ֜ית עֶשְׂרִ֣ים עִ֗יר וְעַד֙ אָבֵ֣ל כְּרָמִ֔ים מַכָּ֖ה גְּדוֹלָ֣ה מְאֹ֑ד וַיִּכָּֽנְעוּ֙ בְּנֵ֣י עַמּ֔וֹן מִפְּנֵ֖י בְּנֵ֥י יִשְׂרָאֵֽל׃ {פ}
(47) After Saul had secured his kingship over Israel, he waged war on every side against all his enemies: against the Moabites, Ammonites, Edomites, the Philistines, and the kings of Zobah; and wherever he turned he acted wickedly against them.
(3) For Your enemies rage,
Your foes assert themselves. (4) They plot craftily against Your people,
take counsel against Your treasured ones. (5) They say, “Let us wipe them out as a nation;
Israel’s name will be mentioned no more.” (6) Unanimous in their counsel
they have made an alliance against You— (7) the clans of Edom and the Ishmaelites,
Moab and the Hagrites, (8) Gebal, Ammon, and Amalek,
Philistia with the inhabitants of Tyre; (9) Assyria too joins forces with them;
they give support to the sons of Lot. Selah.
(10) Deal with them as You did with Midian,
with Sisera, with Jabin,
at the brook Kishon— (11) who were destroyed at En-dor,
who became dung for the field.
Ammon and Moab: special status during shmittah
יָשַׁב חַגַּי הַנָּבִיא, וְאָמַר שְׁלֹשָׁה דְּבָרִים: צָרַת הַבַּת אֲסוּרָה, עַמּוֹן וּמוֹאָב מְעַשְּׂרִין מַעְשַׂר עָנִי בַּשְּׁבִיעִית, וּמְקַבְּלִים גֵּרִים מִן הַקַּרְדּוֹיִין וּמִן הַתַּרְמוֹדִים.
Haggai the prophet sat, and he said three matters of halakha: the rival wife of a daughter is forbidden. Ammon and Moab tithe the poor man’s tithe in the Sabbatical Year. And one accepts converts from the Karduyin and the Tarmodim.
Haggai said that Ammon and Moab tithe the poor man’s tithe in the Sabbatical Year, as the Master said: Many cities were conquered by those who returned from Egypt, and were not conquered by those who returned from Babylonia. And the initial consecration of Eretz Yisrael sanctified it for its time and did not sanctify for the future. And those who returned from Babylonia left those places so that the poor could rely upon them in the Sabbatical Year.
Where did this law originate?
(מ) עמון ומואב מעשרין מעשר עני בשביעית הלכה למשה מסיני.
(40) We tithe the poor tithe in Ammon and Moab on the seventh year, is a 'law of Moshe from Sinai.'
(א) וכאשר מת יהושע בן נון ע"ה למד לזקנים מה שקבל מן הפירוש ומה שהוציאו בזמנו מן הדינים ולא נפל עליו מחלוקת. ואשר נפל בו מחלוקת פסקו בו הדין על פי רוב הזקנים. ועליהם אמר הכתוב (יהושע כד) וכל ימי הזקנים אשר האריכו ימים אחרי יהושע. ואחר כן למדו הזקנים ההם מה שקבלו מפי יהושע אל הנביאים ע"ה והנביאים למדו זה לזה.
(ב) ואין זמן שלא היה בו התבוננות וחדוש הענינים. והיו חכמי כל דור משימים דברי הקודמין עיקר והיו לומדין מהם ומחדשים ענינים. והעיקרים המקובלים לא נחלקו בהם.
(ג) עד הגיע הזמן לאנשי כנסת הגדולה והם חגי זכריה ומלאכי ודניאל וחנניה מישאל ועזריה ועזרא הסופר ונחמיה בן חכליה ומרדכי וזרובבל בן שאלתיאל ונלוו לאלה הנביאים השלמת מאה ועשרים זקן מן החרש והמסגר ודומיהם והתבוננו גם הם כאשר עשו הקודמים להם וגזרו גזירות ותיקנו תקנות והאחרון מן החבורה הטהורה ההיא הוא ראשית החכמים הנזכרים במשנה והוא שמעון הצדיק והיה כהן גדול בדור ההוא.
(1) And when Yehoshua bin Nun, peace be upon him, died, he taught the elders that which he received of the [Torah's oral] explanation; and the laws that they extrapolated during his time about which no disagreement occurred; and [those] about which there occurred a disagreement [and] they decided the law according to the majority of the elders. And about them the verse states (Joshua 24:31), "and all the days of the elders who had length of days after Joshua." And afterward, these elders taught that which they received from Yehoshua to the prophets, peace be upon them. And the prophets learned, one from another.
(2) And there was no time that there was not contemplation and innovation of the matters. And the sages of each generation would make the words of the predecessors the main thing, and they would learn from them and innovate matters. And there was no disagreement [about] the fundamentals passed on.
(3) Until came the time of the men of the Great Assembly – and they were Chaggai, Zechariah, Malachi, Daniel, Chananiah, Mishael, Azariah, Ezra the Scribe, Nechemiah ben Chakhaliah, Mordechai, Zerubavel ben Shaltiel; and accompanying these prophets were the remainder of the hundred and twenty elders, from 'the craftsmen and sentry' and similar to them. And they also contemplated [the laws] as had done their predecessors, and they decreed decrees and ordained ordinances. And the last of this holy fellowship was the beginning of the sages mentioned in the mishnah – and that is Shimon the Righteous. And he was high priest in that generation.
(יג) וזה עיקר יש לך לעמוד על סודו. והוא שהפירושים המקובלים מפי משה אין מחלוקת בהם בשום פנים שהרי מאז ועד עתה לא מצאנו מחלוקת נפלה בזמן מן הזמנים מימות משה ועד רב אשי בין החכמים כדי שיאמר אחד המוציא עין חבירו יוציאו את עינו שנאמר עין בעין ויאמר השני אינו אלא כופר בלבד שחייב לתת.
(13) And [about] this fundamental principle, you must understand its secret. And that is that the explanations that were transmitted from the mouth of Moshe have no disagreement about them in any way. As behold, from then until now, we have not found a disagreement occur among the sages at any time, from the days of Moshe and until Rav Ashi, such that one say, "They take out the eye of one who has taken out the eye of his fellow, as it is stated (Deuteronomy 19:21), 'an eye for an eye'"; and the second one say that it is only indemnity that he has to pay.
Ammon and Moab: Debate Ensues (Ma'aser sheni and ma'aser oni)
On that day they said: what is the law applying to Ammon and Moab in the seventh year?
Rabbi Tarfon decreed tithe for the poor.
And Rabbi Elazar ben Azariah decreed second tithe.
Rabbi Ishmael said: Elazar ben Azariah, you must produce your proof because you are expressing the stricter view and whoever expresses a stricter view has the burden to produce the proof. Rabbi Elazar ben Azariah said to him: Ishmael, my brother, I have not deviated from the sequence of years, Tarfon, my brother, has deviated from it and the burden is upon him to produce the proof.
Rabbi Tarfon answered: Egypt is outside the land of Israel, Ammon and Moab are outside the land of Israel: just as Egypt must give tithe for the poor in the seventh year, so must Ammon and Moab give tithe for the poor in the seventh year.
Rabbi Elazar ben Azariah answered: Babylon is outside the land of Israel, Ammon and Moab are outside the land of Israel: just as Babylon must give second tithe in the seventh year, so must Ammon and Moab give second tithe in the seventh year.
Rabbi Tarfon said: on Egypt which is near, they imposed tithe for the poor so that the poor of Israel might be supported by it during the seventh year; so on Ammon and Moab which are near, we should impose tithe for the poor so that the poor of Israel may be supported by it during the seventh year. Rabbi Elazar ben Azariah said to him: Behold, you are like one who would benefit them with gain, yet you are really as one who causes them to perish. Would you rob the heavens so that dew or rain should not descend? As it is said, "Will a man rob God? Yet you rob me. But you: How have we robbed You? In tithes and heave-offerings" (Malakhi 3:8).
Rabbi Joshua said: Behold, I shall be as one who replies on behalf of Tarfon, my brother, but not in accordance with the substance of his arguments. The law regarding Egypt is a new act and the law regarding Babylon is an old act, and the law which is being argued before us is a new act.
A new act should be argued from [another] new act, but a new act should not be argued from an old act. The law regarding Egypt is the act of the elders and the law regarding Babylon is the act of the prophets, and the law which is being argued before us is the act of the elders. Let one act of the elders be argued from [another] act of the elders, but let not an act of the elders be argued from an act of the prophets.
The votes were counted and they decided that Ammon and Moab should give tithe for the poor in the seventh year.
And when Rabbi Yose ben Durmaskit visited Rabbi Eliezer in Lod he said to him: what new thing did you have in the house of study today? He said to him: their votes were counted and they decided that Ammon and Moab must give tithe for the poor in the seventh year. Rabbi Eliezer wept and said: "The counsel of the Lord is with them that fear him: and his covenant, to make them know it" (Psalms 25:14). Go and tell them: Don't worry about your voting. I received a tradition from Rabbi Yohanan ben Zakkai who heard it from his teacher, and his teacher from his teacher, and so back to a halachah given to Moses from Sinai, that Ammon and Moab must give tithe for the poor in the seventh year.
דְּתַנְיָא: מַעֲשֶׂה בְּרַבִּי יוֹסֵי בֶּן דּוֹרְמַסְקִית שֶׁהָלַךְ לְהַקְבִּיל פְּנֵי רַבִּי (אֶלְעָזָר) [אֱלִיעֶזֶר] בְּלוֹד, אָמַר לוֹ: מָה חִידּוּשׁ הָיָה בְּבֵית הַמִּדְרָשׁ הַיּוֹם? אֲמַר לֵיהּ, נִמְנוּ וְגָמְרוּ: עַמּוֹן וּמוֹאָב מְעַשְּׂרִין מַעְשַׂר עָנִי בַּשְּׁבִיעִית. אָמַר לוֹ: יוֹסֵי, פְּשׁוֹט יָדֶיךָ וְקַבֵּל עֵינֶיךָ. פָּשַׁט יָדָיו וְקִבֵּל עֵינָיו. בָּכָה רַבִּי אֶלְעָזָר וְאָמַר: ״סוֹד ה׳ לִירֵאָיו וּבְרִיתוֹ לְהוֹדִיעָם״. אָמַר לוֹ, לֵךְ אֱמוֹר לָהֶם: אַל תָּחוּשׁוּ לְמִנְיַינְכֶם, כָּךְ מְקּוּבְּלַנִי מֵרַבָּן יוֹחָנָן בֶּן זַכַּאי, שֶׁשָּׁמַע מֵרַבּוֹ וְרַבּוֹ מֵרַבּוֹ: הִלְכְתָא לְמֹשֶׁה מִסִּינַי, עַמּוֹן וּמוֹאָב מְעַשְּׂרִין מַעְשַׂר עָנִי בַּשְּׁבִיעִית. מָה טַעַם — הַרְבֵּה כְּרַכִּים כָּבְשׁוּ עוֹלֵי מִצְרַיִם וְלֹא כְּבָשׁוּם עוֹלֵי בָּבֶל, מִפְּנֵי שֶׁקְּדוּשָּׁה רִאשׁוֹנָה קִדְּשָׁה לִשְׁעָתָהּ וְלֹא קִדְּשָׁה לְעָתִיד לָבֹא, וְהִנִּיחוּם כְּדֵי שֶׁיִּסְמְכוּ עֲלֵיהֶן עֲנִיִּים בַּשְּׁבִיעִית. תָּנָא: לְאַחַר שֶׁנִּתְיַישְּׁבָה דַּעְתּוֹ, אָמַר: יְהִי רָצוֹן שֶׁיַּחְזְרוּ עֵינֵי יוֹסֵי לִמְקוֹמָן, וְחָזְרוּ.
As it is taught in a baraita: There was an incident involving Rabbi Yosei ben Durmaskit, who went to greet Rabbi Eliezer in Lod. Rabbi Elazar said to him: What novel idea was taught today in the study hall? Rabbi Yosei ben Durmaskit said to him: The Sages assembled, counted the votes, and concluded in the lands of Ammon and Moab, one separates the poor man’s tithe there in the Sabbatical Year. Rabbi Elazar said to him in anger: Yosei, extend your hands and catch your eyes. He extended his hands and caught his eyes. Rabbi Elazar wept and said the verse: “The counsel of the Lord is with them who fear Him; and His covenant, to make them know it” (Psalms 25:14). Rabbi Elazar said to Rabbi Yosei to go and say to the Sages in the study hall: Do not be concerned with your counting. This is the tradition that I received from Rabban Yoḥanan ben Zakkai, who heard from his teacher, and his teacher from his teacher: It is a halakha transmitted to Moses from Sinai that in Ammon and Moab one separates the poor man’s tithe in the Sabbatical Year. What is the reason? Those who ascended from Egypt conquered many cities, and those who ascended from Babylonia did not conquer them because the first consecration caused it to be sanctified only for its time and it was not sanctified forever. And those who ascended from Babylonia left those cities, so that the poor could rely upon that produce in the Sabbatical Year. It was taught that after Rabbi Elazar’s mind was put at ease, he said: May it be God’s will that Rabbi Yosei’s eyes should return to their place. And indeed his eyes returned.
and his children shall inherit the land. (14) The counsel of the LORD is for those who fear Him;
to them He makes known His covenant.