It is a positive commandment from the Torah to lend to a poor person when he is in need, as it is said: "If you lend money to my people, to the poor person with you," etc. And this "if" is not optional but obligatory, like "And if you offer a meal-offering of first-fruits," etc., and "And if you make Me an altar of stones," etc. And why did the Torah write it with the language of "if"? Because it is not an obligation like other commandments, for when one has nothing to lend, he is exempt from this commandment. And anyone who does not lend to him when he has the means is called "base," as it is said: "Beware lest there be a base thought in your heart, saying, 'The seventh year approaches,'" etc. And this verse also refers to a loan, since the verse warns that he should not fear lest the Shemittah release it. And thus our sages, of blessed memory, said: Anyone who lends a sela to a poor person in his time of distress, regarding him the verse says, "Then you shall call and Hashem will answer," etc. And it is also a mitzvah to lend to a wealthy person when the wealthy person needs a loan and the lender has the means. Therefore it is written "to my people, to the poor person," to inform us that it is a mitzvah to lend to everyone; for if not so, let it write "if you lend money to the poor person" and no more. Rather, we learn from this that it is a mitzvah to lend to all of Israel, only the explanation of the verse is that a poor person precedes a wealthy person if he does not have enough to lend to both of them. And thus our sages, of blessed memory, explained (Sukkah 49b). They further said: Gemilut chasadim is greater than tzedakah, for tzedakah is for the poor, while gemilut chasadim is for both the poor and the wealthy. And thus we learned in Avot: Rabban Shimon ben Gamliel says, on three things the world stands: on the Torah, on the service, and on gemilut chasadim.
And there are two types of loans: a loan by word of mouth and a loan with a shtar. And these are also divided into two: a loan by word of mouth in the presence of witnesses, and a loan by word of mouth between him and the borrower. Similarly, a loan with a shtar is divided into two: a loan with a shtar without witnesses, where only the borrower writes "I, so-and-so, borrowed from so-and-so a maneh," and a loan with a shtar with witnesses, where the witnesses write in the shtar "We, the undersigned, testify that in our presence so-and-so borrowed from so-and-so," or by an admission where they write "We have testified for ourselves that so-and-so admitted," etc. And also when they performed a kinyan sudar from the borrower in the presence of witnesses, it is like a loan with a shtar, and the witnesses may write a shtar, as will be explained, for an ordinary kinyan is intended for writing. And specifically when the witnesses write for the purpose of a shtar, then it has the law of a shtar; but when they wrote merely as a memorandum of the matter, it does not have the law of a shtar, such as if they wrote an explanation of what so-and-so admitted in our presence and did not write "We have testified for ourselves," this is a sign that they only wrote it as a memorandum of the matter, and this does not have the law of a loan with a shtar, but rather like a loan by word of mouth. And the advice of our teachers, of blessed memory, is not to lend without witnesses or without a shtar, so that the borrower will not be able to deny it.
And know that every loan with a shtar that will be explained in these laws refers to a shtar with witnesses, for a shtar with the borrower's own signature does not have the law of a loan with a shtar, and it will be explained in these laws. And know a great principle: that all the loans and the shtarot that will be explained in these laws are not the iska loan shtarot that are customary among us in all the provinces, for this is not gemilut chasadim but commerce to take a known profit according to a heter iska. And these laws are explained in Yoreh Deah, the laws of interest. But in these laws, they are loans of gemilut chasadim. And keep this principle, for iska shtarot have other laws.
מ"ע מן התורה להלות לעני כשצריך שנא' אם כסף תלוה את עמי את העני עמך וגו' ואם זה אינו רשות אלא חובה כמו ואם תקריב מנחת בכורים וגו' ואם מזבח אבנים תעשה לי וגו' ולמה כתבה התורה בלשון אם משום שאינו חובה כשאר מצות דכשאין לו מה להלות פטור ממצוה זו וכל שאינו מלוהו כשיש לו נקרא בליעל שנא' השמר לך פן יהי' דבר עם לבבך בליעל לאמר קרבה שנת השבע וגו' ופסוק זה גם אהלואה קאי מדמזהיר קרא שלא יירא פן תשמיטנו שביעית וכך אמרו חז"ל כל המלוה סלע לעני בשעת דוחקו עליו הכתוב אומר אז תקרא וד' יענה וגו' וגם לעשיר מצוה להלות כשצריך העשיר להלואה ויש לו להמלוה ולכן כתיב את עמי את העני להשמיענו דלכולם מצוה להלות דאל"כ לכתוב אם כסף תלוה את העני ולא יותר אלא ש"מ דלכל ישראל מצוה להלות רק פי' הפסוק הוא דעני קודם לעשיר אם אין לו להלות לשניהם וכך פירשו חז"ל (סוכה מ"ט ב') עוד אמרו גדולה ג"ח יותר מן הצדקה שצדקה לעניים וג"ח בין לעניים ובין לעשירים וכך שנינו באבות רשב"ג אומר על שלשה דברים העולם עומד על התורה ועל העבודה ועל ג"ח ושני מיני הלואות יש מלוה בע"פ ומלוה בשטר וגם אלו נחלקות לשתים מלוה בע"פ בפני עדים ומלוה בע"פ בינו לבין הלוה וכן מלוה בשטר נחלקות לשתים מלוה בשטר בלא עדים רק שהלוה כותב אני פלוני לויתי מפלוני מנה ומלוה בשטר בעדים שהעדים כותבים בשטר אנחנו ח"מ מעידים שבפנינו לוה פלוני מפלוני או בהודאה שכותבים העדנו על עצמנו שפלוני הודה וכו' וגם כשקנו בק"ס מהלוה בפני עדים הוי כמלוה בשטר ויכולים העדים לכתוב שטר כמו שיתבאר דסתם קנין לכתיבה עומד ודוקא כשהעדים כותבין לשם שטר אז דין שטר יש לו אבל כשכתבו לזכרון דברים בעלמא אין לו דין שטר כגון שכתבו ביאור מה שהודה פלוני בפנינו ולא כתבו העדנו על עצמנו זהו סימן שלא כתבו רק לזכרון דברים בעלמא ואין לזה דין מלוה בשטר אלא כמלוה בע"פ ועצת רבותינו ז"ל שלא להלות בלא עדים או בלא שטר כדי שהלוה לא יוכל לכפור ודע שכל מלוה בשטר שיתבארו בהלכות אלו הם שטר בעדים דאלו שטר בחתימת ידי הלוה אין לזה דין מלוה בשטר ויתבאר בהלכות אלו וכלל גדול תדע שכל ההלואות והשטרות שיתבארו בהלכות אלו אינם ההלואות שטרות עיסקא שנהוגות אצלנו בכל המדינות דזה אינו ג"ח רק מסחור ליקח ריוח ידוע ע"פ היתר עיסקא ודינים אלו מתבארים יו"ד ה' ריבית ובהלכות אלו הם הלואות ג"ח ושמור כלל זה כי שטרות עיסקא יש להם דינים אחרים: