<Page> Exhibit 5 Bingham McCutchen LLP 150 Federal Street Boston, Massachusetts 02110 tel: 617-951-8000 fax: 617-951-8736 August 18, 2004 iBasis, Inc. iBasis Global, Inc. iBasis Holdings, Inc. iBasis Securities Corporation 20 Second Avenue Burlington, MA 01803 RE: REGISTRATION STATEMENT ON FORM S-1 UNDER THE SECURITIES ACT OF 1933 Dear Ladies and Gentlemen: We have acted as counsel to (i) iBasis, Inc., a Delaware corporation (the "COMPANY"), (ii) iBasis Global, Inc., a Delaware corporation ("GLOBAL"), (iii) iBasis Holdings, Inc., a Delaware corporation ("HOLDINGS"), and (iv) iBasis Securities Corporation, a Massachusetts corporation ("SECURITIES" and together with Global and Holdings, the "SUBSIDIARY GUARANTORS"), in connection with the registration under the Securities Act of 1933, as amended (the "ACT"), of (A) $29 million aggregate principal amount of the Company's 8% Secured Convertible Notes due 2007 (the "NEW SECURED NOTES"), (B) Guarantees (the "GUARANTEES") of the New Secured Notes by the Subsidiary Guarantors and (C) 20,961,971 shares of the Company's common stock, $0.001 par value per share (the "COMMON STOCK"), including (1) 15,675,675 shares of Common Stock issuable upon conversion of the New Secured Notes, plus such indeterminate number of shares of Common Stock that may be issuable as a result of adjustments of the conversion price of the New Secured Notes (the "NEW SECURED NOTE SHARES"), (2) 5,176,065 shares of Common Stock (the "WARRANT SHARES") issuable upon conversion of certain warrants (the "WARRANTS"), dated as of June 18, 2004, and (3) 110,231 other previously-issued shares of Common Stock (the "OTHER SHARES"), pursuant to a Registration Statement on Form S-1 (as amended, the "REGISTRATION STATEMENT"), initially filed with the Securities and Exchange Commission on July 13, 2004. The New Secured Notes and the Guarantees were issued pursuant to an Indenture (the "INDENTURE"), dated as of June 18, 2004, by and among the Company, the Subsidiary Guarantors and The Bank of New York, as the Trustee thereunder (the "TRUSTEE"). Capitalized terms used herein and not defined shall have the respective meanings ascribed to them in the Indenture. In connection with this opinion, we have examined originals or copies of: the Registration Statement; the Indenture; the Global Note, issued by the Company on June 18, 2004, representing $29.0 million aggregate principal amount of the New Secured Notes; the Guarantees; the form of Warrant Certificate, issued by the Company on June 18, 2004, representing the Warrants; resolutions duly adopted by the board of directors of each of the Company and the Subsidiary Guarantors; and certified copies of the certificate of incorporation or articles of organization of each of the Company and the Subsidiary Guarantors, each as amended to date. In addition, we have examined such other <Page> corporate and public records and agreements, instruments, certificates and other documents as we have deemed necessary or appropriate for purposes of this opinion. The Indenture, the Guarantees and the New Secured Notes are referred to herein collectively as the "TRANSACTION DOCUMENTS." We have assumed the genuineness of all signatures, the conformity to the originals of all documents reviewed by us as copies, the authenticity and completeness of all original documents reviewed by us in original or copy form and the legal competence of each individual executing any document. For purposes of this opinion, we have made such examination of law as we have deemed necessary. This opinion is limited solely to the internal substantive laws of the State of New York as applied by courts located in New York; with respect to Securities, the Massachusetts Business Corporation Law as applied by courts located in Massachusetts; the federal laws of the United States of America (except for tax, antitrust, blue sky and securities laws, as to which we express no opinion); and the Delaware General Corporation Law, as applied by courts located in Delaware, and the applicable provisions of the Delaware Constitution and the reported judicial decisions interpreting those laws; and we express no opinion as to the laws of any other jurisdiction. Our opinion is further subject to the following exceptions, qualifications and assumptions, all of which we understand to be acceptable to you: (a) The enforcement of any obligations of, or any security interest granted by, the Company, the Subsidiary Guarantors or any other Person, whether under any of the Transaction Documents or otherwise, may be limited by bankruptcy, insolvency, reorganization, moratorium, marshaling or other laws and rules of law affecting the enforcement generally of creditors' rights and remedies, including, without limitation, fraudulent conveyance and fraudulent transfer laws (including such as may deny giving effect to waivers of debtors' or guarantors' rights); and we express no opinion as to the status under any fraudulent conveyance laws or fraudulent transfer laws of any of the obligations of, or any security interest granted by, any of the Company, the Subsidiary Guarantors, or any other Person, whether under any of the Transaction Documents or otherwise, or to the applicable law with respect to such matters. (b) The enforcement of the rights of any Person may in all cases be subject to an implied duty of good faith and fair dealing and to general principles of equity (regardless of whether such enforceability is considered in a proceeding at law or in equity), including, without limitation, concepts of materiality and reasonableness. (c) We express no opinion as to the effect of events occurring, circumstances arising, or changes of law becoming effective or occurring, after the date hereof on the matters addressed in this opinion letter, and we assume no responsibility to inform you of additional or changed facts, or changes in law, of which we may become aware. (d) We have assumed that each of the Transaction Documents to which each of the Subsidiary Guarantors is a party is necessary or convenient to the conduct, promotion or attainment of the business of such Subsidiary Guarantor. 2 <Page> (e) We have assumed that the Company will have a sufficient number of authorized but unissued shares of Common Stock available under its certificate of incorporation to accommodate the issuance of the New Secured Note Shares and the Warrant Shares. Based upon the foregoing, and subject to the limitations and qualifications set forth above, we are of the opinion that: 1. Each of the New Secured Notes and the Guarantees to which the Company and the Subsidiary Guarantors are party is a valid and binding obligation of the Company and/or each such Subsidiary Guarantor, enforceable against the Company and each such Subsidiary Guarantor in accordance with its respective terms. 2. The New Secured Note Shares and the Warrant Shares have been duly authorized by the Company, and, when issued in accordance with the terms of the New Secured Notes and the Warrants, will be validly issued, fully paid and nonassessable. 3. The Other Shares have been duly authorized and validly issued by the Company, and are fully paid and nonassessable. We consent to the filing of this opinion with the Securities and Exchange Commission as an exhibit to the Registration Statement and the reference to us under the heading "Legal Matters" in the related prospectus. Very truly yours, /s/ BINGHAM McCUTCHEN LLP - ------------------------- BINGHAM McCUTCHEN LLP 3