Four men compiled the Quran during the lifetime of the Messenger of Allah ﷺ, all of them from the Ansar. They were Ubayy bin Kaab, Muaz bin Jabal, Zayd bin Thabit, and a man from the Ansar known by the kunya Abu Zayd.
جمع القرآن على عهد رسول الله ﷺ أربعة، كلهم من الأنصار: أبي بن كعب، ومعاذ بن جبل، وزيد بن ثابت، ورجل من الأنصار يكنى أبا زيد.
Bukhari narrated it in the Virtues of the Quran (5003), and Muslim in the Virtues of the Companions (2465: 120), both through the route of Amr bin Asim, who said, Hammam narrated to us, who said, Qatada narrated to us, who said, I asked Anas bin Malik, "Who compiled the Quran?" and he mentioned it.His saying, "compiled the Quran," means wrote it down.