EXHIBIT 5.1 Allen & Overy LLP One Bishops Square WPP Group plc London E1 6AO United Kingdom 27 Farm Street London Tel: +44 (0)20 3088 0000 W1J 5RJ Fax: +44 (0)20 3088 0088 United Kingdom Our ref 16432-00481 CO:6202856.5 31 July 2007 Dear Sirs, Registration Statement on Form S-8 of WPP Group plc (the Registration Statement) 1. You have requested the opinion of Allen & Overy LLP (A&O) with respect to certain matters of English law in relation to shares of WPP Group plc (WPP), in connection with the proposed registration under the United States Securities Act of 1933, as amended, of 4,824,238 of WPP's ordinary shares of 10 pence each (the Ordinary Shares) in respect of awards over the Ordinary Shares that have been granted under the 24/7 Media, Inc. 1998 Stock Incentive Plan, the 24/7 Media, Inc. 2001 Stock Incentive Plan for Non-Officers and the 24/7 Real Media, Inc. 2002 Stock Incentive Plan (together the Plans). The proposed registration of Ordinary Shares follows the merger (the Merger) of 24/7 Real Media, Inc. (24/7) with TS Transaction, Inc., a wholly owned subsidiary of WPP (the Transaction). We understand that certain of the Ordinary Shares will be newly issued and allotted at the relevant time and that certain of the Ordinary Shares (the ESOP Shares) will be transferred by the trustees of the WPP Group Plc UK ESOP, the WPP Group Plc Grantor Trust or the WPP Group Plc ROW ESOP (together, the WPP ESOPs). 2. In connection with this opinion we have examined copies of: (a) the memorandum and articles of association of WPP (the Memorandum and Articles); (b) the rules of each of the Plans (the Rules); and (c) the ordinary and special resolutions of WPP passed on 26 June 2007 (the Shareholder Resolutions). 3. Except as stated above, we have not examined any contracts, instruments or other documents entered into or affecting WPP or the Transaction or any corporate records of WPP and have not made any other enquiries concerning WPP or the Transaction. 4. Our opinion is confined solely to the laws of England in force at the date of this opinion and is governed by, and construed in accordance with, English law. Accordingly, we express no opinion with regard to any system of law other than the laws of England as currently applied by the English courts. In particular, we express no opinion on European Community law as it affects a jurisdiction other than England and we have made no investigation of the laws of any other jurisdiction including, without limitation, the federal laws of the United States of America and we do not express or imply any opinion on such laws. 5. We have assumed, without further enquiry, that: (a) insofar as any obligation falls to be performed in any jurisdiction outside England, its performance will not be illegal or ineffective by virtue of the laws of that jurisdiction and will not violate the public policy of any jurisdiction; (b) all signatures on the executed documents which, or copies (whether photocopies, certified copies, facsimile copies or electronic copies) of which, we have examined are genuine and that such copies conform to the original documents executed; (c) all documents submitted to us as originals and upon which we have sought to rely are genuine and complete and none of the documents furnished to us has been amended, supplemented or terminated; (d) no law of any jurisdiction other than England affects our conclusions; (e) all statements made to us and all facts stated in any documents upon which we have sought to rely are true and correct; (f) the Memorandum and Articles which we have examined are those in force; (g) the Rules that we have examined are those in force, were properly adopted by 24/7 and have been and will be operated in accordance with their terms, as amended to reflect the Transaction; (h) the terms of the Merger are effective to confer the right to receive American Depositary Shares representing Ordinary Shares on holders of outstanding but unvested options to purchase shares of common stock of 24/7 under the Plans, on exercise of such options, as described in the Registration Statement; (i) the general meeting of the shareholders of WPP at which the Shareholder Resolutions were passed was duly convened and held and that the Shareholder Resolutions were passed in the form of the resolutions contained in the notice of such meeting and the Shareholder Resolutions have not been and will not be subsequently amended, modified or revoked before the allotment and issue of any new Ordinary Shares; (j) at the time of the issue of any new Ordinary Shares, WPP will have a nominal amount of authorised but unissued Ordinary Shares of 10 pence each at least equal to the nominal amount of such new Ordinary Shares; (k) at the time of the issue of any new Ordinary Shares, the board of directors will have sufficient authority to: (i) allot the number of new Ordinary Shares being issued; and (ii) to allot the number of new Ordinary Shares being issued as if section 89 of the Companies Act 1985 did not apply; (l) any new Ordinary Shares will when issued be subscribed for under the Plans wholly in cash at not less than their nominal value; (m) admission of any new Ordinary Shares to the Official List maintained by the Financial Services Authority and to trading on the London Stock Exchange plc will become effective in accordance with the applicable rules of the Financial Services Authority and the London Stock Exchange plc; (n) a meeting of the board of directors of WPP or a duly authorised and constituted committee of the board of directors of WPP has been or will be duly convened and held at which it was or will be resolved to allot and issue any new Ordinary Shares. 2 31 July 2007 6. On the basis of the foregoing, and having regard to such considerations of English law in force at the date of this letter as we deem relevant and subject as set out below, we are of the opinion that the new Ordinary Shares to be registered by WPP will, when issued by WPP in connection with the Plans, be validly issued, credited as fully paid and no further contributions in respect of them will be required to be made to WPP by the holders of them, by reason of their being such holders. 7. This opinion is subject to the qualifications set out below: (a) the opinions set out above are subject to all applicable limitations arising from the laws of bankruptcy, insolvency, liquidation, administration, reorganisation, moratorium, reconstruction or similar laws and general principles of law affecting the rights of creditors generally; (b) the effectiveness of terms exculpating a party from a liability or duty otherwise owed is limited by English law; and (c) equitable remedies such as an order for specific performance or the issue of an injunction, are available only at the discretion of the court and certain obligations may result in a claim for damages only, as opposed to specific performance. This opinion is addressed to you solely for your own purpose in connection with the Registration Statement and may not be used or relied upon by any other person or for any other purposes without A&O's prior written consent. A&O consents in relation to the filing of this letter as an exhibit to the Registration Statement. In giving such consent A&O does not admit that it comes within the category of persons whose consent is required under section 7 of the United States Securities Act of 1933, as amended. Yours faithfully, /s/ Allen & Overy LLP Allen & Overy LLP 3 31 July 2007