10 years of export website building · serving exporters and SOHO

HTML Color Codes: Hex & RGB Chart for B2B Sites

Site Building Docs Published 2024-12-26 By XGTU Editorial reads: 3

You don't need a designer to pick colors for a foreign-trade site. Set three values first — primary, secondary, body text — then grab ready-made hex codes from the HTML color table and drop them into your CSS. Use light shades for backgrounds, dark shades only for headings and buttons, and never set body copy in pure black #000000. After the change, check how fast your hero image loads and keep LCP under 2.5 seconds. That moves inquiries more than a prettier palette.

A B2B export site only needs three color values

Your primary color is what customers remember first. Machine parts suppliers go deep blue; home goods go warm white with wood tones. The primary color appears in exactly three places: the logo, the active nav state, and the CTA button. The more often it shows up elsewhere, the messier the page looks.

The secondary color separates sections. A light gray in the #F5F5F5 to #FAFAFA range is enough for backgrounds, cards, and table zebra striping. Body text in #333333 or #2B2B2B is softer than pure black and still has enough contrast on white.

Once the three values are set, write them as CSS variables and call them site-wide. For how the palette fits into the page skeleton, see our website build service — there's a ready page structure to compare against.

HTML color codes: common RGB and hex values side by side

In the table, R.G.B is three numbers from 0 to 255, and the hex column is the #RRGGBB form. Both describe the same color. Browsers accept either in CSS, but pick hex for consistency.

English nameR.G.BHexCommon use
Snow255 250 250#FFFAFAPage background
GhostWhite248 248 255#F8F8FFCard background
WhiteSmoke245 245 245#F5F5F5Table zebra rows
Gainsboro220 220 220#DCDCDCDividers and borders
White255 255 255#FFFFFFContent areas, forms
Black0 0 0#000000Icons only, never body text
Ivory255 255 240#FFFFF0Warm background
FloralWhite255 250 240#FFFAF0Home and lifestyle site background
OldLace253 245 230#FDF5E6Textile and gift backgrounds
Linen250 240 230#FAF0E6Linen-texture section
AntiqueWhite250 235 215#FAEBD7Highlight block background
PapayaWhip255 239 213#FFEFD5Promo bar
BlanchedAlmond255 235 205#FFEBCDButton hover state
Bisque255 228 196#FFE4C4Tag background
PeachPuff255 218 185#FFDAB9Price callout
NavajoWhite255 222 173#FFDEADSale badge
Moccasin255 228 181#FFE4B5Card border
Cornsilk255 248 220#FFF8DCTable header background
Seashell255 245 238#FFF5EEContent blocks
Honeydew240 255 240#F0FFF0Eco-friendly themes
MintCream245 255 250#F5FFFAMedical and health
Azure240 255 255#F0FFFFCool-tone sections
AliceBlue240 248 255#F0F8FFTech backgrounds
Lavender230 230 250#E6E6FABeauty accents
LavenderBlush255 240 245#FFF0F5Feminine palettes
MistyRose255 228 225#FFE4E1Alert blocks

The rule is simple: values starting at 255 are light enough for backgrounds; dark values whose three numbers add up to less than 300 are for buttons and headings only. If your site uses more than six colors, stop and cut.

Which shade goes where on the page

The same value in the wrong place does the opposite of what you want. #FFFFFF is a clean background but turns to mush as button text. The table below goes section by section — fill it in and you won't go far wrong.

Page areaRecommended valueNotes
Top navigation#FFFFFF or #F8F8FFWhite background, dark text, logo in the primary color
Hero headline#2B2B2BType big enough to say who you are and what you solve in 3 seconds
Hero imageNo color — use a real product photoMust be an img tag with fetchpriority="high"
Product spec tableHeader #F5F5F5, rows #FAFAFAProduct pages need a spec table and MOQ
CTA buttonPrimary color, e.g. #0B5FFFOne per screen; repeating it makes it stop working
Inquiry form#FFFFFFKeep only name, email, and requirement fields
FooterBackground #333333, text #FFFFFFCompany info and SSL badge

How color relates to Core Web Vitals in 2026

Color itself doesn't slow you down; the decoration you add for color does. If your hero uses a big image as a CSS background-image, the browser has to parse the CSS before it even discovers the image, which pushes LCP back. Do it right: use an img tag with fetchpriority="high". The 2026 good thresholds are LCP ≤ 2.5s, INP ≤ 200ms, and CLS ≤ 0.1. INP officially replaced FID in March 2024.

The cheapest CLS fix is hard-coding width and height on every image. Wrong placeholder dimensions make content jump while the page loads — the customer goes to click the inquiry button and it moves out from under them. INP is mostly third-party scripts: GA4, Meta Pixel, live chat, popups. The usual fix is to defer them until the user first touches, scrolls, or presses a key.

About 53% of users leave if a mobile page takes more than 3 seconds to load. A perfect palette is worth nothing if the page won't open. And after you fix things, wait 4 weeks: Core Web Vitals uses a 28-day rolling window of real users, so Search Console won't change overnight.

The 4 most common color mistakes

  • Setting body copy in pure black #000000. The contrast is too harsh on screen — three lines into a long text and your eyes are tired. Switch to #333333 or #2B2B2B.
  • Using light gray as a text color. #F5F5F5 is a background only; as text it's as good as not writing anything. Body text needs at least 4.5:1 contrast against the background.
  • Spreading the primary color across the whole site. Nav, buttons, headings, and links all in one color means customers can't tell what to click, and your CTA is wasted.
  • Copying a competitor's palette outright. You can copy the hex codes but not the logic — their deep blue speaks to industrial buyers, while your product is fast-moving consumer goods. Copy it and you just look like a knockoff. Analyzing competitor websites is about information structure and the order of selling points, not about lifting color numbers.

5 steps to get the colors into your site

  1. Decide three values: primary, secondary, body text. Write them down first; don't change them while you build.
  2. Turn them into CSS variables, such as --main, --bg, --text. Adjust variables site-wide instead of scattering raw hex codes.
  3. Check text contrast one by one in the browser dev tools. Replace anything below 4.5:1 for body copy.
  4. Add width and height to every image, and fetchpriority="high" to the hero image.
  5. In week 4 after launch, check the Core Web Vitals report in Search Console and confirm nothing dropped to "Needs improvement".

If inquiries still don't move after the redesign, color usually isn't the problem. Read why your B2B site gets no traffic or inquiries — nine times out of ten it's the product spec table and the form fields. For how build options differ by use case, see the plan and price comparison.

FAQ

How do I convert hex color codes and RGB?

Split #RRGGBB into three pairs and convert each pair to decimal to get RGB. For example, #FFFAFA splits into FF, FA, FA, which is 255, 250, 250. Going the other way, convert the three decimal numbers to hex and join them. Both forms render identically on the web.

Which primary color brings more inquiries on a B2B site?

There's no universal color. Industrial, machinery, and hardware sites do better with deep blue and dark gray; home, gift, and textile sites fit off-white and oat tones. The test is that the primary color appears only on buttons and the logo — high saturation is fine there, while body text and backgrounds stay low-saturation.

Does website color affect Google rankings?

Not directly. There's no palette signal in ranking. But color affects time on page and click behavior, which indirectly affects conversion. What actually decides whether you rank is whether pages are crawlable and indexable, and whether your content answers customer questions.

How long until I see results after changing colors?

The visual change is instant; the data takes time. Core Web Vitals uses a 28-day rolling window, and Search Console needs 4 weeks to reflect reality. Compare inquiry conversion over a full month — don't draw conclusions from three days of data.

15023755537
WeChat
WeChat QR code Scan to add us
Back to top