The article systematizes data about the number of St. Petersburg foreign population in the first half of the 18th century, for the first time cites quantitative and qualitative indicators characterizing the religious, national and social composition of its foreign diaspora. The materials for the statistical reconstruction were the results of the analysis of the St. Petersburg Catholic and Protestant parish registers and the foreigners' databases created on the basis of these church books. To identify demographic structures, the authors used the methods of descriptive statistics and comparative analysis of statistical indicators, and to determine the number of foreigners (“inozemtsy”), they used the method of reconstructing values using constant coefficients expressing the ratio of the adult believers' number to the sum of church rites for a certain time period. As a result, they found that the greatest concentration of foreigners (at the level of 10-13%) in St. Petersburg was observed in the Petrine era, and under Anna Ioannovna and Empress Elizabeth Petrovna their share fell to 6-7%. The number of foreigners was a relatively constant value and amounted to about 4 thousands adult men and women at the end of the reign of Peter the Great, and about 4-5 thousand people of both sexes in the 1730s and 1740s. As parts of the foreign population, the authors separately took into account groups of Germans, French, Italians, Poles, Dutch people, Finns, Swedes, Armenians, Tatars, and other nationalities. The authors publish the results of a special study, during which the size of various religious groups of St. Petersburg residents was determined - such as Catholics, Lutherans, Calvinists, believers of the Armenian Apostolic Church. They substantiate the conclusion that initially it was not Germans, as is traditionally considered, but Swedes and Finns that prevailed among the foreigners of St. Petersburg, and only by the middle of the 18th century the Germans became the most common group of foreigners, accounting for about half of their number. The largest social stratum of the foreign population in the city was the craft-working (future petty-bourgeois), they included masters and apprentices of the guild craft, artisans, all kinds of civilian specialists and persons who were in service. In the 1730s, this layer of Petersburgians incorporated about three thousand foreigners of both sexes, they made up a significant percentage of the commercial and industrial population of the city and strengthened the stratum of Posadsky residents. Turning to the questions of the socioprofessional composition of the St. Petersburg foreign society of the first half of the 18th century, the authors came to the conclusion that the confessional factor affected the choosing of the type of activity by foreigners.