how can revome the border or spacing between tr and td even i have border="0" cellpadding="0" cellspacing="0" in my table.

Dani AI

Generated

Thread author reported persistent gaps between table rows/cells in an HTML email even after removing the usual table spacing attributes. This is a common email-layout problem: different mail clients use different renderers (web engines, mobile engines, Outlook’s Word engine), and several apply default spacing or ignore external styles. ’s suggestion to check styles and caching is useful, but email-specific fixes are usually required.

A reliable email pattern is to apply inline resets to every table and cell, and to neutralize Outlook’s extra spacing. The following is a minimal, email-safe example showing those key pieces:

<table role="presentation" style="border-collapse:collapse;border-spacing:0;mso-table-lspace:0pt;mso-table-rspace:0pt;">
  <tr>
    <td style="padding:0;margin:0;border:none;font-size:0;line-height:0;">
      <img src="image.jpg" width="600" height="200" alt="" style="display:block;border:0;outline:none;text-decoration:none;">
    </td>
  </tr>
</table>

Common causes and quick checks:

  • Global styles or classes can override inline rules in some web clients; inline styles are the most reliable for email.
  • Images can introduce gaps when treated as inline elements; forcing display:block and setting the containing td to font-size:0 / line-height:0 removes that whitespace.
  • Outlook may add table spacing; add the mso- table lspace/rspace reset and keep border-collapse:collapse.
  • Nested tables, a wrapper body margin, or linked images with default borders can also create visible lines — ensure every nested table/td has the same zero-padding/margin rules.

If spacing persists, extract a minimal test case (single table) and test it in multiple clients. That isolates whether the issue is an inherited stylesheet, a particular client quirk, or markup around the table.

Are you using a stylesheet too? If so check you haven't got it set in your stylesheet.

If that still doesn't work see if you have any other classes set that could have a border?

Try refreshing your cache?

Is the website hosted on a CDN? That will have a time delay.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.