HTML
Copy
<form action="https://formspree.io/f/{FORM_ID}" class="fs-form fs-layout__2-column" target="_top" method="POST" > <fieldset> <legend class="fs-fieldset-title">Customer Information</legend> <div class="fs-field"> <label class="fs-label" for="customer-name">Customer Name</label> <input class="fs-input" id="customer-name" name="customer-name" placeholder="Enter your full name" required /> </div> <div class="fs-field"> <label class="fs-label" for="email-address">Email Address</label> <input class="fs-input" id="email-address" name="email-address" placeholder="Enter your email address" required /> </div> <div class="fs-field"> <label class="fs-label" for="phone-number">Phone Number</label> <input class="fs-input" id="phone-number" name="phone-number" placeholder="Enter your phone number (optional)" /> </div> </fieldset> <fieldset> <legend class="fs-fieldset-title">Order and Product Details</legend> <div class="fs-field"> <label class="fs-label" for="order-number"> Order Number / Invoice Number </label> <input class="fs-input" id="order-number" name="order-number" placeholder="Enter your order or invoice number" required /> </div> <div class="fs-field"> <label class="fs-label" for="purchase-date">Date of Purchase</label> <input class="fs-input" id="purchase-date" name="purchase-date" placeholder="Select the purchase date" required /> </div> <div class="fs-field"> <label class="fs-label" for="product-name">Product Name</label> <input class="fs-input" id="product-name" name="product-name" placeholder="Enter the product name" required /> </div> <div class="fs-field"> <label class="fs-label" for="product-sku"> Product SKU or Model Number </label> <input class="fs-input" id="product-sku" name="product-sku" placeholder="Enter the SKU or model number" required /> </div> <div class="fs-field"> <label class="fs-label" for="quantity-returned"> Quantity Being Returned </label> <input class="fs-input" id="quantity-returned" name="quantity-returned" placeholder="Enter the quantity" required /> </div> <div class="fs-field"> <label class="fs-label" for="return-reason">Reason for Return</label> <select class="fs-select" id="return-reason" name="return-reason" required > <option value="defective">Defective</option> <option value="wrong-item">Wrong Item Shipped</option> <option value="changed-mind">Changed Mind</option> <option value="other">Other</option> </select> </div> <div class="fs-field"> <label class="fs-label">Is the Item Opened or Used?</label> <div class="fs-radio-group"> <div class="fs-radio-field"> <div class="fs-radio-wrapper"> <input class="fs-radio" id="item-used-yes" name="item-used" required type="radio" value="yes" /> </div> <div> <label class="fs-label" for="item-used-yes">Yes</label> </div> </div> <div class="fs-radio-field"> <div class="fs-radio-wrapper"> <input class="fs-radio" id="item-used-no" name="item-used" required type="radio" value="no" /> </div> <div> <label class="fs-label" for="item-used-no">No</label> </div> </div> </div> </div> <div class="fs-field"> <label class="fs-label" for="preferred-resolution"> Preferred Resolution </label> <select class="fs-select" id="preferred-resolution" name="preferred-resolution" required > <option value="replacement">Replacement</option> <option value="refund">Refund</option> <option value="repair">Repair</option> <option value="store-credit">Store Credit</option> </select> </div> <div class="fs-field col-span-full"> <label class="fs-label" for="upload-photos"> Upload Photos of the Item </label> <input class="fs-input" id="upload-photos" name="upload-photos" placeholder="Add a link after uploading files to Google Drive, Dropbox, etc." /> </div> </fieldset> <fieldset> <legend class="fs-fieldset-title">Return Details</legend> <div class="fs-field col-span-full"> <label class="fs-label" for="return-shipping-address"> Return Shipping Address (if needed) </label> <textarea class="fs-textarea" id="return-shipping-address" name="return-shipping-address" placeholder="Enter return shipping address (optional)" ></textarea> </div> <div class="fs-field col-span-full"> <label class="fs-label" for="additional-comments"> Additional Comments or Special Instructions </label> <textarea class="fs-textarea" id="additional-comments" name="additional-comments" placeholder="Any other details or notes" ></textarea> </div> <div class="fs-checkbox-field col-span-full"> <div class="fs-checkbox-wrapper"> <input aria-describedby="acknowledgment-description" class="fs-checkbox" id="acknowledgment" name="acknowledgment" required type="checkbox" value="agreed" /> </div> <div> <label class="fs-label" for="acknowledgment"> Acknowledgment of Return Policy </label> <p class="fs-description" id="acknowledgment-description"> I have read and agree to the return policy. </p> </div> </div> </fieldset> <div class="fs-button-group"> <button class="fs-button" type="submit">Submit</button> </div> </form>
Show moreCSS
Copy
@import url("https://fonts.googleapis.com/css2?family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap"); /** Variables **/ :root { --color-background: #cbd5e1; --color-background-alt: #3a9092; --color-border-active: #23494c; --color-border-default: #94a3b8; --color-highlight: #7ecac7; --color-primary: #23494c; --color-primary-active: #122d30; --color-text-default: #0f172a; --color-text-muted: #475569; --font-family-body: "Open Sans", sans-serif; --font-family-display: "Nunito Sans", sans-serif; } /** Base **/ *, ::before, ::after { box-sizing: border-box; } * { border: 0; margin: 0; padding: 0; } body { -webkit-font-smoothing: antialiased; font-family: var(--font-family-body); font-optical-sizing: auto; font-style: normal; } button, input, optgroup, select, textarea { font-family: inherit; font-feature-settings: inherit; font-variation-settings: inherit; font-size: 100%; font-weight: inherit; line-height: inherit; color: inherit; margin: 0; padding: 0; } [type="checkbox"], [type="radio"], [type="range"] { appearance: none; flex-shrink: 0; padding: 0; user-select: none; } [type="checkbox"]:focus, [type="radio"]:focus, [type="range"]:focus { outline: none; } /** Components **/ .fs-form { display: grid; row-gap: 1.5rem; } .fs-form:where(.fs-layout__2-column) { column-gap: 1.5rem; grid-template-columns: 1fr 1fr; } fieldset { display: grid; margin: 1.5rem 0; row-gap: 1.5rem; } .fs-form:where(.fs-layout__2-column) fieldset { column-gap: 1.5rem; grid-template-columns: 1fr 1fr; grid-column: 1 / -1; } .fs-fieldset-title { color: var(--color-text-default); font-family: var(--font-family-display); font-size: 1.25rem; font-weight: 500; line-height: 1.75rem; margin-bottom: 1.5rem; grid-column: 1 / -1; } .fs-field { display: flex; flex-direction: column; row-gap: 0.375rem; } .fs-label { color: var(--color-text-default); display: block; font-family: var(--font-family-display); font-size: 0.875rem; font-weight: 500; line-height: 1.25rem; } .fs-description { color: var(--color-text-muted); display: block; font-size: 0.875rem; line-height: 1.25rem; } .fs-button-group { display: flex; flex-direction: row-reverse; column-gap: 1.5rem; } .fs-form:where(.fs-layout__2-column) .fs-button-group { grid-column: 1 / -1; } .fs-button { background-color: var(--color-primary); border-radius: 0.375rem; color: white; cursor: pointer; font-size: 0.875rem; font-weight: 500; line-height: 1rem; padding: 1rem 2rem; transition-duration: 200ms; transition-property: background-color; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); } .fs-button:hover { background-color: var(--color-primary-active); } .fs-button:focus-visible { background-color: var(--color-primary-active); outline: 3px solid var(--color-highlight); } .fs-input, .fs-select { appearance: none; border-radius: 0.375rem; border-width: 0; box-shadow: var(--color-border-default) 0 0 0 1px inset; color: var(--color-text-default); font-size: 1rem; height: 2.5rem; line-height: 1.5rem; outline: none; padding-left: 0.75rem; padding-right: 0.75rem; } .fs-input:focus-visible, .fs-select:focus-visible { box-shadow: var(--color-border-active) 0 0 0 1.5px inset; outline: 3px solid var(--color-highlight); outline-offset: 0; } .fs-input::placeholder { color: var(--color-text-muted); } .fs-checkbox-group, .fs-radio-group { display: flex; flex-direction: column; row-gap: 0.5rem; } .fs-checkbox-field, .fs-radio-field { column-gap: 0.5rem; display: flex; } :is(.fs-checkbox-field, .fs-radio-field) .fs-label + .fs-description { margin-top: 0.125rem; } .fs-checkbox-wrapper, .fs-radio-wrapper { align-items: center; display: flex; height: 1.25rem; } .fs-checkbox, .fs-radio { background-color: #fff; border: 1px solid var(--color-text-default); height: 1rem; width: 1rem; } .fs-checkbox { border-radius: 0.25rem; } .fs-radio { border-radius: 100%; } .fs-checkbox:checked, .fs-radio:checked { background-color: var(--color-primary); background-position: center; background-repeat: no-repeat; background-size: 100% 100%; border-color: transparent; } .fs-checkbox:checked { background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e"); } .fs-radio:checked { background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e"); } .fs-checkbox:focus-visible, .fs-radio:focus-visible { outline: 3px solid var(--color-highlight); outline-offset: 0; } .fs-select { background-color: #fff; background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e"); background-position: right 0.5rem center; background-repeat: no-repeat; background-size: 1.5em 1.5em; padding-right: 2.5rem; } .fs-slider { background: transparent; cursor: pointer; height: 1.25rem; width: 100%; } .fs-slider::-moz-range-track { background-color: var(--color-background); border-radius: 0.5rem; height: 0.5rem; } .fs-slider::-webkit-slider-runnable-track { background-color: var(--color-background); border-radius: 0.5rem; height: 0.5rem; } .fs-slider::-moz-range-thumb { background-color: var(--color-primary); border: none; /* Removes extra border that FF applies */ border-radius: 50%; height: 1.25rem; width: 1.25rem; } .fs-slider::-webkit-slider-thumb { appearance: none; background-color: var(--color-primary); border-radius: 50%; height: 1.25rem; margin-top: -0.375rem; /* Centers thumb on the track */ width: 1.25rem; } .fs-slider:focus-visible::-moz-range-thumb { outline: 2px solid var(--color-primary); outline-offset: 2px; } .fs-slider:focus-visible::-webkit-slider-thumb { outline: 2px solid var(--color-primary); outline-offset: 2px; } .fs-switch { background-color: var(--color-background-alt); background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='white'/%3e%3c/svg%3e"); background-position: left center; background-repeat: no-repeat; border-radius: 1.5rem; cursor: pointer; height: 1.5rem; transition-duration: 200ms; transition-property: background-color, background-position; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); width: 2.75rem; } .fs-switch:checked { background-color: var(--color-primary); background-position: right center; } .fs-switch:focus-visible { outline: 3px solid var(--color-highlight); outline-offset: 0; } .fs-textarea { appearance: none; border-radius: 0.375rem; border-width: 0; box-shadow: var(--color-border-default) 0 0 0 1px inset; color: var(--color-primary); font-size: 1rem; line-height: 1.5rem; outline: none; padding: 0.5rem 0.75rem; resize: vertical; } .fs-textarea:focus-visible { box-shadow: var(--color-border-active) 0 0 0 1.5px inset; outline: 3px solid var(--color-highlight); outline-offset: 0; } .fs-textarea::placeholder { color: var(--color-text-muted); } /** Utilities **/ .col-span-full { grid-column: 1 / -1; }
Show more
HTML/Tailwind
Copy
<form action="https://formspree.io/f/{FORM_ID}" class="grid grid-cols-2 gap-x-6 gap-y-6" target="_top" method="POST" > <fieldset> <legend class="col-span-full mb-6 font-[family-name:--font-family-display] text-xl font-medium text-[--color-text-default]" > Customer Information </legend> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="customer-name" > Customer Name </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="customer-name" name="customer-name" placeholder="Enter your full name" required /> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="email-address" > Email Address </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="email-address" name="email-address" placeholder="Enter your email address" required /> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="phone-number" > Phone Number </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="phone-number" name="phone-number" placeholder="Enter your phone number (optional)" /> </div> </fieldset> <fieldset> <legend class="col-span-full mb-6 font-[family-name:--font-family-display] text-xl font-medium text-[--color-text-default]" > Order and Product Details </legend> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="order-number" > Order Number / Invoice Number </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="order-number" name="order-number" placeholder="Enter your order or invoice number" required /> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="purchase-date" > Date of Purchase </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="purchase-date" name="purchase-date" placeholder="Select the purchase date" required /> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="product-name" > Product Name </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="product-name" name="product-name" placeholder="Enter the product name" required /> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="product-sku" > Product SKU or Model Number </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="product-sku" name="product-sku" placeholder="Enter the SKU or model number" required /> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="quantity-returned" > Quantity Being Returned </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="quantity-returned" name="quantity-returned" placeholder="Enter the quantity" required /> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="return-reason" > Reason for Return </label> <select class="bg-caret-down h-10 appearance-none rounded-md border-0 bg-white bg-[size:1.5em_1.5em] bg-[position:right_0.5rem_center] bg-no-repeat px-3 pe-10 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="return-reason" name="return-reason" required > <option value="defective">Defective</option> <option value="wrong-item">Wrong Item Shipped</option> <option value="changed-mind">Changed Mind</option> <option value="other">Other</option> </select> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" > Is the Item Opened or Used? </label> <div class="flex flex-col gap-y-2"> <div class="flex gap-x-2"> <div class="flex h-5 items-center"> <input class="checked:bg-radio-checked h-4 w-4 rounded-full border border-solid border-[--color-text-default] bg-white checked:border-transparent checked:bg-[--color-primary] checked:bg-[size:100%_100%] checked:bg-center checked:bg-no-repeat focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight]" id="item-used-yes" name="item-used" required type="radio" value="yes" /> </div> <div> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="item-used-yes" > Yes </label> </div> </div> <div class="flex gap-x-2"> <div class="flex h-5 items-center"> <input class="checked:bg-radio-checked h-4 w-4 rounded-full border border-solid border-[--color-text-default] bg-white checked:border-transparent checked:bg-[--color-primary] checked:bg-[size:100%_100%] checked:bg-center checked:bg-no-repeat focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight]" id="item-used-no" name="item-used" required type="radio" value="no" /> </div> <div> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="item-used-no" > No </label> </div> </div> </div> </div> <div class="flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="preferred-resolution" > Preferred Resolution </label> <select class="bg-caret-down h-10 appearance-none rounded-md border-0 bg-white bg-[size:1.5em_1.5em] bg-[position:right_0.5rem_center] bg-no-repeat px-3 pe-10 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="preferred-resolution" name="preferred-resolution" required > <option value="replacement">Replacement</option> <option value="refund">Refund</option> <option value="repair">Repair</option> <option value="store-credit">Store Credit</option> </select> </div> <div class="col-span-full flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="upload-photos" > Upload Photos of the Item </label> <input class="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="upload-photos" name="upload-photos" placeholder="Add a link after uploading files to Google Drive, Dropbox, etc." /> </div> </fieldset> <fieldset> <legend class="col-span-full mb-6 font-[family-name:--font-family-display] text-xl font-medium text-[--color-text-default]" > Return Details </legend> <div class="col-span-full flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="return-shipping-address" > Return Shipping Address (if needed) </label> <textarea class="resize-y appearance-none rounded-md border-0 px-3 py-2 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="return-shipping-address" name="return-shipping-address" placeholder="Enter return shipping address (optional)" ></textarea> </div> <div class="col-span-full flex flex-col gap-y-1.5"> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="additional-comments" > Additional Comments or Special Instructions </label> <textarea class="resize-y appearance-none rounded-md border-0 px-3 py-2 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="additional-comments" name="additional-comments" placeholder="Any other details or notes" ></textarea> </div> <div class="col-span-full flex gap-x-2"> <div class="flex h-5 items-center"> <input aria-describedby="acknowledgment-description" class="checked:bg-checkbox-checked h-4 w-4 rounded border border-solid border-[--color-text-default] bg-white checked:border-transparent checked:bg-[--color-primary] checked:bg-[size:100%_100%] checked:bg-center checked:bg-no-repeat focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight]" id="acknowledgment" name="acknowledgment" required type="checkbox" value="agreed" /> </div> <div> <label class="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" for="acknowledgment" > Acknowledgment of Return Policy </label> <p class="mt-0.5 block text-sm text-[--color-text-muted]" id="acknowledgment-description" > I have read and agree to the return policy. </p> </div> </div> </fieldset> <div class="col-span-full flex flex-row-reverse gap-x-6"> <button class="cursor-pointer rounded-md bg-[--color-primary] px-8 py-4 text-sm font-medium leading-4 text-white transition-colors duration-200 hover:bg-[--color-primary-active] focus-visible:bg-[--color-primary-active] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-[--color-highlight]" type="submit" > Submit </button> </div> </form>
Show moreCSS
Copy
@import url("https://fonts.googleapis.com/css2?family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap"); @tailwind base; @tailwind components; @tailwind utilities; @layer base { :root { --color-background: #cbd5e1; --color-background-alt: #3a9092; --color-border-active: #23494c; --color-border-default: #94a3b8; --color-highlight: #7ecac7; --color-primary: #23494c; --color-primary-active: #122d30; --color-text-default: #0f172a; --color-text-muted: #475569; --font-family-body: "Open Sans", sans-serif; --font-family-display: "Nunito Sans", sans-serif; } *, ::before, ::after { box-sizing: border-box; } * { border: 0; margin: 0; padding: 0; } body { -webkit-font-smoothing: antialiased; font-family: var(--font-family-body); font-optical-sizing: auto; font-style: normal; } button, input, optgroup, select, textarea { font-family: inherit; font-feature-settings: inherit; font-variation-settings: inherit; font-size: 100%; font-weight: inherit; line-height: inherit; color: inherit; margin: 0; padding: 0; } [type="checkbox"], [type="radio"], [type="range"] { appearance: none; flex-shrink: 0; padding: 0; user-select: none; } [type="checkbox"]:focus, [type="radio"]:focus, [type="range"]:focus { outline: none; } } @layer components { .fs-slider { background: transparent; cursor: pointer; height: 1.25rem; width: 100%; } .fs-slider::-moz-range-track { background-color: var(--color-background); border-radius: 0.5rem; height: 0.5rem; } .fs-slider::-webkit-slider-runnable-track { background-color: var(--color-background); border-radius: 0.5rem; height: 0.5rem; } .fs-slider::-moz-range-thumb { background-color: var(--color-primary); border: none; /* Removes extra border that FF applies */ border-radius: 50%; height: 1.25rem; width: 1.25rem; } .fs-slider::-webkit-slider-thumb { appearance: none; background-color: var(--color-primary); border-radius: 50%; height: 1.25rem; margin-top: -0.375rem; /* Centers thumb on the track */ width: 1.25rem; } .fs-slider:focus-visible::-moz-range-thumb { outline: 2px solid var(--color-primary); outline-offset: 2px; } .fs-slider:focus-visible::-webkit-slider-thumb { outline: 2px solid var(--color-primary); outline-offset: 2px; } } @layer utilities { .bg-caret-down { background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e"); } .bg-checkbox-checked { background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e"); } .bg-radio-checked { background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e"); } .bg-switch-thumb { background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='white'/%3e%3c/svg%3e"); } }
Show more
React
Copy
// Make sure to run npm install @formspree/react // For more help visit https://formspr.ee/react-help import React from "react"; import { useForm, ValidationError } from "@formspree/react"; export function ExampleForm() { const [state, handleSubmit] = useForm("FORM_ID"); if (state.succeeded) { return <p>Thanks for joining!</p>; } return ( <form className="fs-form fs-layout__2-column" onSubmit={handleSubmit}> <fieldset> <legend className="fs-fieldset-title">Customer Information</legend> <div className="fs-field"> <label className="fs-label" htmlFor="customer-name"> Customer Name </label> <input className="fs-input" id="customer-name" name="customer-name" placeholder="Enter your full name" required /> </div> <div className="fs-field"> <label className="fs-label" htmlFor="email-address"> Email Address </label> <input className="fs-input" id="email-address" name="email-address" placeholder="Enter your email address" required /> </div> <div className="fs-field"> <label className="fs-label" htmlFor="phone-number"> Phone Number </label> <input className="fs-input" id="phone-number" name="phone-number" placeholder="Enter your phone number (optional)" /> </div> </fieldset> <fieldset> <legend className="fs-fieldset-title">Order and Product Details</legend> <div className="fs-field"> <label className="fs-label" htmlFor="order-number"> Order Number / Invoice Number </label> <input className="fs-input" id="order-number" name="order-number" placeholder="Enter your order or invoice number" required /> </div> <div className="fs-field"> <label className="fs-label" htmlFor="purchase-date"> Date of Purchase </label> <input className="fs-input" id="purchase-date" name="purchase-date" placeholder="Select the purchase date" required /> </div> <div className="fs-field"> <label className="fs-label" htmlFor="product-name"> Product Name </label> <input className="fs-input" id="product-name" name="product-name" placeholder="Enter the product name" required /> </div> <div className="fs-field"> <label className="fs-label" htmlFor="product-sku"> Product SKU or Model Number </label> <input className="fs-input" id="product-sku" name="product-sku" placeholder="Enter the SKU or model number" required /> </div> <div className="fs-field"> <label className="fs-label" htmlFor="quantity-returned"> Quantity Being Returned </label> <input className="fs-input" id="quantity-returned" name="quantity-returned" placeholder="Enter the quantity" required /> </div> <div className="fs-field"> <label className="fs-label" htmlFor="return-reason"> Reason for Return </label> <select className="fs-select" id="return-reason" name="return-reason" required > <option value="defective">Defective</option> <option value="wrong-item">Wrong Item Shipped</option> <option value="changed-mind">Changed Mind</option> <option value="other">Other</option> </select> </div> <div className="fs-field"> <label className="fs-label">Is the Item Opened or Used?</label> <div className="fs-radio-group"> <div className="fs-radio-field"> <div className="fs-radio-wrapper"> <input className="fs-radio" id="item-used-yes" name="item-used" required type="radio" value="yes" /> </div> <div> <label className="fs-label" htmlFor="item-used-yes"> Yes </label> </div> </div> <div className="fs-radio-field"> <div className="fs-radio-wrapper"> <input className="fs-radio" id="item-used-no" name="item-used" required type="radio" value="no" /> </div> <div> <label className="fs-label" htmlFor="item-used-no"> No </label> </div> </div> </div> </div> <div className="fs-field"> <label className="fs-label" htmlFor="preferred-resolution"> Preferred Resolution </label> <select className="fs-select" id="preferred-resolution" name="preferred-resolution" required > <option value="replacement">Replacement</option> <option value="refund">Refund</option> <option value="repair">Repair</option> <option value="store-credit">Store Credit</option> </select> </div> <div className="fs-field col-span-full"> <label className="fs-label" htmlFor="upload-photos"> Upload Photos of the Item </label> <input className="fs-input" id="upload-photos" name="upload-photos" placeholder="Add a link after uploading files to Google Drive, Dropbox, etc." /> </div> </fieldset> <fieldset> <legend className="fs-fieldset-title">Return Details</legend> <div className="fs-field col-span-full"> <label className="fs-label" htmlFor="return-shipping-address"> Return Shipping Address (if needed) </label> <textarea className="fs-textarea" id="return-shipping-address" name="return-shipping-address" placeholder="Enter return shipping address (optional)" /> </div> <div className="fs-field col-span-full"> <label className="fs-label" htmlFor="additional-comments"> Additional Comments or Special Instructions </label> <textarea className="fs-textarea" id="additional-comments" name="additional-comments" placeholder="Any other details or notes" /> </div> <div className="fs-checkbox-field col-span-full"> <div className="fs-checkbox-wrapper"> <input aria-describedby="acknowledgment-description" className="fs-checkbox" id="acknowledgment" name="acknowledgment" required type="checkbox" value="agreed" /> </div> <div> <label className="fs-label" htmlFor="acknowledgment"> Acknowledgment of Return Policy </label> <p className="fs-description" id="acknowledgment-description"> I have read and agree to the return policy. </p> </div> </div> </fieldset> <div class="fs-button-group"> <button className="fs-button" type="submit"> Submit </button> </div> </form> ); }
Show moreCSS
Copy
@import url("https://fonts.googleapis.com/css2?family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap"); /** Variables **/ :root { --color-background: #cbd5e1; --color-background-alt: #3a9092; --color-border-active: #23494c; --color-border-default: #94a3b8; --color-highlight: #7ecac7; --color-primary: #23494c; --color-primary-active: #122d30; --color-text-default: #0f172a; --color-text-muted: #475569; --font-family-body: "Open Sans", sans-serif; --font-family-display: "Nunito Sans", sans-serif; } /** Base **/ *, ::before, ::after { box-sizing: border-box; } * { border: 0; margin: 0; padding: 0; } body { -webkit-font-smoothing: antialiased; font-family: var(--font-family-body); font-optical-sizing: auto; font-style: normal; } button, input, optgroup, select, textarea { font-family: inherit; font-feature-settings: inherit; font-variation-settings: inherit; font-size: 100%; font-weight: inherit; line-height: inherit; color: inherit; margin: 0; padding: 0; } [type="checkbox"], [type="radio"], [type="range"] { appearance: none; flex-shrink: 0; padding: 0; user-select: none; } [type="checkbox"]:focus, [type="radio"]:focus, [type="range"]:focus { outline: none; } /** Components **/ .fs-form { display: grid; row-gap: 1.5rem; } .fs-form:where(.fs-layout__2-column) { column-gap: 1.5rem; grid-template-columns: 1fr 1fr; } fieldset { display: grid; margin: 1.5rem 0; row-gap: 1.5rem; } .fs-form:where(.fs-layout__2-column) fieldset { column-gap: 1.5rem; grid-template-columns: 1fr 1fr; grid-column: 1 / -1; } .fs-fieldset-title { color: var(--color-text-default); font-family: var(--font-family-display); font-size: 1.25rem; font-weight: 500; line-height: 1.75rem; margin-bottom: 1.5rem; grid-column: 1 / -1; } .fs-field { display: flex; flex-direction: column; row-gap: 0.375rem; } .fs-label { color: var(--color-text-default); display: block; font-family: var(--font-family-display); font-size: 0.875rem; font-weight: 500; line-height: 1.25rem; } .fs-description { color: var(--color-text-muted); display: block; font-size: 0.875rem; line-height: 1.25rem; } .fs-button-group { display: flex; flex-direction: row-reverse; column-gap: 1.5rem; } .fs-form:where(.fs-layout__2-column) .fs-button-group { grid-column: 1 / -1; } .fs-button { background-color: var(--color-primary); border-radius: 0.375rem; color: white; cursor: pointer; font-size: 0.875rem; font-weight: 500; line-height: 1rem; padding: 1rem 2rem; transition-duration: 200ms; transition-property: background-color; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); } .fs-button:hover { background-color: var(--color-primary-active); } .fs-button:focus-visible { background-color: var(--color-primary-active); outline: 3px solid var(--color-highlight); } .fs-input, .fs-select { appearance: none; border-radius: 0.375rem; border-width: 0; box-shadow: var(--color-border-default) 0 0 0 1px inset; color: var(--color-text-default); font-size: 1rem; height: 2.5rem; line-height: 1.5rem; outline: none; padding-left: 0.75rem; padding-right: 0.75rem; } .fs-input:focus-visible, .fs-select:focus-visible { box-shadow: var(--color-border-active) 0 0 0 1.5px inset; outline: 3px solid var(--color-highlight); outline-offset: 0; } .fs-input::placeholder { color: var(--color-text-muted); } .fs-checkbox-group, .fs-radio-group { display: flex; flex-direction: column; row-gap: 0.5rem; } .fs-checkbox-field, .fs-radio-field { column-gap: 0.5rem; display: flex; } :is(.fs-checkbox-field, .fs-radio-field) .fs-label + .fs-description { margin-top: 0.125rem; } .fs-checkbox-wrapper, .fs-radio-wrapper { align-items: center; display: flex; height: 1.25rem; } .fs-checkbox, .fs-radio { background-color: #fff; border: 1px solid var(--color-text-default); height: 1rem; width: 1rem; } .fs-checkbox { border-radius: 0.25rem; } .fs-radio { border-radius: 100%; } .fs-checkbox:checked, .fs-radio:checked { background-color: var(--color-primary); background-position: center; background-repeat: no-repeat; background-size: 100% 100%; border-color: transparent; } .fs-checkbox:checked { background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e"); } .fs-radio:checked { background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e"); } .fs-checkbox:focus-visible, .fs-radio:focus-visible { outline: 3px solid var(--color-highlight); outline-offset: 0; } .fs-select { background-color: #fff; background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e"); background-position: right 0.5rem center; background-repeat: no-repeat; background-size: 1.5em 1.5em; padding-right: 2.5rem; } .fs-slider { background: transparent; cursor: pointer; height: 1.25rem; width: 100%; } .fs-slider::-moz-range-track { background-color: var(--color-background); border-radius: 0.5rem; height: 0.5rem; } .fs-slider::-webkit-slider-runnable-track { background-color: var(--color-background); border-radius: 0.5rem; height: 0.5rem; } .fs-slider::-moz-range-thumb { background-color: var(--color-primary); border: none; /* Removes extra border that FF applies */ border-radius: 50%; height: 1.25rem; width: 1.25rem; } .fs-slider::-webkit-slider-thumb { appearance: none; background-color: var(--color-primary); border-radius: 50%; height: 1.25rem; margin-top: -0.375rem; /* Centers thumb on the track */ width: 1.25rem; } .fs-slider:focus-visible::-moz-range-thumb { outline: 2px solid var(--color-primary); outline-offset: 2px; } .fs-slider:focus-visible::-webkit-slider-thumb { outline: 2px solid var(--color-primary); outline-offset: 2px; } .fs-switch { background-color: var(--color-background-alt); background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='white'/%3e%3c/svg%3e"); background-position: left center; background-repeat: no-repeat; border-radius: 1.5rem; cursor: pointer; height: 1.5rem; transition-duration: 200ms; transition-property: background-color, background-position; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); width: 2.75rem; } .fs-switch:checked { background-color: var(--color-primary); background-position: right center; } .fs-switch:focus-visible { outline: 3px solid var(--color-highlight); outline-offset: 0; } .fs-textarea { appearance: none; border-radius: 0.375rem; border-width: 0; box-shadow: var(--color-border-default) 0 0 0 1px inset; color: var(--color-primary); font-size: 1rem; line-height: 1.5rem; outline: none; padding: 0.5rem 0.75rem; resize: vertical; } .fs-textarea:focus-visible { box-shadow: var(--color-border-active) 0 0 0 1.5px inset; outline: 3px solid var(--color-highlight); outline-offset: 0; } .fs-textarea::placeholder { color: var(--color-text-muted); } /** Utilities **/ .col-span-full { grid-column: 1 / -1; }
Show more
React/Tailwind
Copy
// Make sure to run npm install @formspree/react // For more help visit https://formspr.ee/react-help import React from "react"; import { useForm, ValidationError } from "@formspree/react"; export function ExampleForm() { const [state, handleSubmit] = useForm("FORM_ID"); if (state.succeeded) { return <p>Thanks for joining!</p>; } return ( <form className="grid grid-cols-2 gap-x-6 gap-y-6" onSubmit={handleSubmit}> <fieldset> <legend className="col-span-full mb-6 font-[family-name:--font-family-display] text-xl font-medium text-[--color-text-default]"> Customer Information </legend> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="customer-name" > Customer Name </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="customer-name" name="customer-name" placeholder="Enter your full name" required /> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="email-address" > Email Address </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="email-address" name="email-address" placeholder="Enter your email address" required /> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="phone-number" > Phone Number </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="phone-number" name="phone-number" placeholder="Enter your phone number (optional)" /> </div> </fieldset> <fieldset> <legend className="col-span-full mb-6 font-[family-name:--font-family-display] text-xl font-medium text-[--color-text-default]"> Order and Product Details </legend> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="order-number" > Order Number / Invoice Number </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="order-number" name="order-number" placeholder="Enter your order or invoice number" required /> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="purchase-date" > Date of Purchase </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="purchase-date" name="purchase-date" placeholder="Select the purchase date" required /> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="product-name" > Product Name </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="product-name" name="product-name" placeholder="Enter the product name" required /> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="product-sku" > Product SKU or Model Number </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="product-sku" name="product-sku" placeholder="Enter the SKU or model number" required /> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="quantity-returned" > Quantity Being Returned </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="quantity-returned" name="quantity-returned" placeholder="Enter the quantity" required /> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="return-reason" > Reason for Return </label> <select className="bg-caret-down h-10 appearance-none rounded-md border-0 bg-white bg-[size:1.5em_1.5em] bg-[position:right_0.5rem_center] bg-no-repeat px-3 pe-10 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="return-reason" name="return-reason" required > <option value="defective">Defective</option> <option value="wrong-item">Wrong Item Shipped</option> <option value="changed-mind">Changed Mind</option> <option value="other">Other</option> </select> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]"> Is the Item Opened or Used? </label> <div className="flex flex-col gap-y-2"> <div className="flex gap-x-2"> <div className="flex h-5 items-center"> <input className="checked:bg-radio-checked h-4 w-4 rounded-full border border-solid border-[--color-text-default] bg-white checked:border-transparent checked:bg-[--color-primary] checked:bg-[size:100%_100%] checked:bg-center checked:bg-no-repeat focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight]" id="item-used-yes" name="item-used" required type="radio" value="yes" /> </div> <div> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="item-used-yes" > Yes </label> </div> </div> <div className="flex gap-x-2"> <div className="flex h-5 items-center"> <input className="checked:bg-radio-checked h-4 w-4 rounded-full border border-solid border-[--color-text-default] bg-white checked:border-transparent checked:bg-[--color-primary] checked:bg-[size:100%_100%] checked:bg-center checked:bg-no-repeat focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight]" id="item-used-no" name="item-used" required type="radio" value="no" /> </div> <div> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="item-used-no" > No </label> </div> </div> </div> </div> <div className="flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="preferred-resolution" > Preferred Resolution </label> <select className="bg-caret-down h-10 appearance-none rounded-md border-0 bg-white bg-[size:1.5em_1.5em] bg-[position:right_0.5rem_center] bg-no-repeat px-3 pe-10 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="preferred-resolution" name="preferred-resolution" required > <option value="replacement">Replacement</option> <option value="refund">Refund</option> <option value="repair">Repair</option> <option value="store-credit">Store Credit</option> </select> </div> <div className="col-span-full flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="upload-photos" > Upload Photos of the Item </label> <input className="h-10 appearance-none rounded-md border-0 px-3 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="upload-photos" name="upload-photos" placeholder="Add a link after uploading files to Google Drive, Dropbox, etc." /> </div> </fieldset> <fieldset> <legend className="col-span-full mb-6 font-[family-name:--font-family-display] text-xl font-medium text-[--color-text-default]"> Return Details </legend> <div className="col-span-full flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="return-shipping-address" > Return Shipping Address (if needed) </label> <textarea className="resize-y appearance-none rounded-md border-0 px-3 py-2 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="return-shipping-address" name="return-shipping-address" placeholder="Enter return shipping address (optional)" /> </div> <div className="col-span-full flex flex-col gap-y-1.5"> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="additional-comments" > Additional Comments or Special Instructions </label> <textarea className="resize-y appearance-none rounded-md border-0 px-3 py-2 text-[--color-text-default] outline-none ring-1 ring-inset ring-[--color-border-default] placeholder:text-[--color-text-muted] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight] focus-visible:ring-[1.5px] focus-visible:ring-inset focus-visible:ring-[--color-border-active]" id="additional-comments" name="additional-comments" placeholder="Any other details or notes" /> </div> <div className="col-span-full flex gap-x-2"> <div className="flex h-5 items-center"> <input aria-describedby="acknowledgment-description" className="checked:bg-checkbox-checked h-4 w-4 rounded border border-solid border-[--color-text-default] bg-white checked:border-transparent checked:bg-[--color-primary] checked:bg-[size:100%_100%] checked:bg-center checked:bg-no-repeat focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-offset-0 focus-visible:outline-[--color-highlight]" id="acknowledgment" name="acknowledgment" required type="checkbox" value="agreed" /> </div> <div> <label className="block font-[family-name:--font-family-display] text-sm font-medium text-[--color-text-default]" htmlFor="acknowledgment" > Acknowledgment of Return Policy </label> <p className="mt-0.5 block text-sm text-[--color-text-muted]" id="acknowledgment-description" > I have read and agree to the return policy. </p> </div> </div> </fieldset> <div class="col-span-full flex flex-row-reverse gap-x-6"> <button className="cursor-pointer rounded-md bg-[--color-primary] px-8 py-4 text-sm font-medium leading-4 text-white transition-colors duration-200 hover:bg-[--color-primary-active] focus-visible:bg-[--color-primary-active] focus-visible:outline focus-visible:outline-[3px] focus-visible:outline-[--color-highlight]" type="submit" > Submit </button> </div> </form> ); }
Show moreCSS
Copy
@import url("https://fonts.googleapis.com/css2?family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap"); @tailwind base; @tailwind components; @tailwind utilities; @layer base { :root { --color-background: #cbd5e1; --color-background-alt: #3a9092; --color-border-active: #23494c; --color-border-default: #94a3b8; --color-highlight: #7ecac7; --color-primary: #23494c; --color-primary-active: #122d30; --color-text-default: #0f172a; --color-text-muted: #475569; --font-family-body: "Open Sans", sans-serif; --font-family-display: "Nunito Sans", sans-serif; } *, ::before, ::after { box-sizing: border-box; } * { border: 0; margin: 0; padding: 0; } body { -webkit-font-smoothing: antialiased; font-family: var(--font-family-body); font-optical-sizing: auto; font-style: normal; } button, input, optgroup, select, textarea { font-family: inherit; font-feature-settings: inherit; font-variation-settings: inherit; font-size: 100%; font-weight: inherit; line-height: inherit; color: inherit; margin: 0; padding: 0; } [type="checkbox"], [type="radio"], [type="range"] { appearance: none; flex-shrink: 0; padding: 0; user-select: none; } [type="checkbox"]:focus, [type="radio"]:focus, [type="range"]:focus { outline: none; } } @layer components { .fs-slider { background: transparent; cursor: pointer; height: 1.25rem; width: 100%; } .fs-slider::-moz-range-track { background-color: var(--color-background); border-radius: 0.5rem; height: 0.5rem; } .fs-slider::-webkit-slider-runnable-track { background-color: var(--color-background); border-radius: 0.5rem; height: 0.5rem; } .fs-slider::-moz-range-thumb { background-color: var(--color-primary); border: none; /* Removes extra border that FF applies */ border-radius: 50%; height: 1.25rem; width: 1.25rem; } .fs-slider::-webkit-slider-thumb { appearance: none; background-color: var(--color-primary); border-radius: 50%; height: 1.25rem; margin-top: -0.375rem; /* Centers thumb on the track */ width: 1.25rem; } .fs-slider:focus-visible::-moz-range-thumb { outline: 2px solid var(--color-primary); outline-offset: 2px; } .fs-slider:focus-visible::-webkit-slider-thumb { outline: 2px solid var(--color-primary); outline-offset: 2px; } } @layer utilities { .bg-caret-down { background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e"); } .bg-checkbox-checked { background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e"); } .bg-radio-checked { background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e"); } .bg-switch-thumb { background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='white'/%3e%3c/svg%3e"); } }
Show more
Get started in just a few steps. Create a free account and choose New Form. Choose from our growing list of actions, from Airtable to Zendesk and everything in between. Replace with the form endpoint in the code above with the ID from your new form. Don’t forget to include a name attribute for every input. Formspree works great with static websites, but also plays nicely with many hosting platforms like Shopify, Webflow and more. See the guides below. Follow these steps to copy and paste this form into your Shopify theme and get it working in minutes.
Sign up for a free Formspree account and create a new form.
Once created, you’ll get a unique form endpoint like
Scroll up and copy the full HTML form code shown above. Don’t forget to replace the
Go to your Shopify Admin and navigate to Online Store > Themes > Customize.
Select the page where you want the form to appear, then add a new Custom Liquid section.
Paste the copied HTML into the Custom Liquid field and save.
Scroll up and copy the CSS snippet provided on this page. These styles are optimized for the form layout and appearance.
In your Shopify Admin, go to Online Store > Themes > Actions > Edit Code.
Open the
Return to the page where you added the form. You should now see your styled Formspree form live in your Shopify store.
Test it out and then hit “Publish” to make it live for customers.
Contact forms that work out of the box with top website platforms.How to use this form
Create a form on Formspree
Add actions and validation rules
Update your form's action
<form action="https://formspree.io/f/{form_id}" method="post">Tweak your form's code
Deploy your form to your hosting platform
How to Use This Form in Your Shopify Store
Create a Form on Formspree
https://formspree.io/f/your-form-id
.
Copy the HTML from this Library Page
FORM_ID
in the action
attribute with your actual form ID.
Paste the Form into a Shopify Page
Copy the CSS Styles
Paste the CSS into Your Shopify Theme
assets/base.css
file (or your theme’s main CSS file) and paste the copied CSS at the very end.
Save the file.
Preview and Publish
Integration Guides
Smooth and efficient product returns are vital to maintaining customer satisfaction and operational efficiency in the e-commerce space. One of the most important tools businesses use to manage returns is the RMA form. Short for Return Merchandise Authorization (also sometimes called Return Materials Authorization), the RMA form ensures that both customers and companies can track, process, and resolve returns systematically.
Whether a customer needs a refund, a repair, or a product replacement, an RMA form formalizes the request and keeps all parties informed. By implementing a clear RMA process, businesses not only improve customer trust but also enhance inventory control, minimize fraud, and streamline back-end operations.
In this article, you will learn what an RMA form is and how to implement one using Formspree’s template above!
Return Merchandise Authorization (RMA) is a formal approval granted by a company to a customer wishing to return a purchased product. It signifies that the company acknowledges the customer’s request and provides specific instructions for how the return should be handled. The RMA form is the document (either digital or physical) that captures essential details about the return request.
An RMA form typically includes fields for customer contact information, product details, the reason for return, and the preferred resolution (such as a refund or replacement). By collecting information upfront, companies can quickly review requests, issue RMA numbers for tracking, and ensure products are returned properly for inspection, refund, or exchange.
RMA forms serve as the first point of contact when customers initiate a return, guiding both the customer and the company through a standardized workflow. Without a formalized RMA process, businesses risk facing unorganized returns, lost products, customer dissatisfaction, and increased fraud.
For customers, RMA forms provide a clear, professional way to request a return while receiving assurance that their issue will be handled promptly. For businesses, RMA forms act as a critical tracking tool, linking each returned item to an original purchase, ensuring that returns are valid, and providing the data needed to make informed decisions about refunds, repairs, or replacements. Ultimately, a well-designed RMA process protects both sides and fosters a smoother, more transparent customer experience.
At its core, an RMA form is the structured entry point for managing returns. When a customer encounters an issue with a product, whether it’s defective, damaged, incorrect, or simply unwanted, the RMA form is used to initiate a formal return request. The company reviews the submitted form, validates the request based on its return policies, and issues an RMA number. This number is crucial, as it tracks the return throughout the entire process.
The RMA process typically handles several types of returns:
By positioning the RMA form at the beginning of the return journey, businesses can help ensure that returns are authorized, documented, and processed efficiently, minimizing confusion and delays for both the customer and the company.
An effective RMA form captures all the necessary information needed to process a return quickly and accurately. Typical fields include:
Full name, shipping and billing address, phone number, and email address to facilitate communication and return shipping.
Model number, serial number, purchase date, and original order number to verify the transaction and identify the correct item.
A dropdown menu or free text field where customers specify why they are returning the product (e.g., defective, wrong item, no longer needed).
Options allowing the customer to request a refund, replacement, repair, or exchange based on company policy.
Upload or attach a copy of the original receipt, invoice, or order confirmation to confirm eligibility for return.
An optional field where customers can provide more context, such as describing the issue in detail or offering product feedback.
Clear guidelines outlining how the customer should package the return, where to ship it, and deadlines for sending back the item to qualify for a refund or replacement.
The RMA process follows a structured, step-by-step workflow that ensures returns are properly authorized, tracked, and resolved. Here’s how it typically unfolds:
Many companies also use automated systems integrated with their order management or CRM platforms to track RMA requests in real time. Customer service teams play a key role, assisting customers during each step if issues arise and ensuring a smooth return experience.
Implementing an organized RMA process centered around a detailed RMA form provides major advantages for businesses and customers alike:
Standardizing how returns are initiated and processed helps companies handle high volumes of returns efficiently, reducing manual work and errors.
Each return is logged against the original sale, helping businesses maintain accurate inventory records, process refunds appropriately, and better forecast product issues or warranty claims.
By requiring proof of purchase and formal approval before a return is accepted, companies can deter fraudulent claims and prevent returns of ineligible or counterfeit items.
A clear and professional return process reassures customers that their issues will be addressed fairly, building loyalty and improving overall satisfaction, even when the original purchase didn’t meet expectations.
Creating an effective RMA form is about more than just collecting information; it’s about making the process easy and reassuring for customers while ensuring the business gets the details needed for efficient processing. Here are some best practices:
By following these practices, companies can ensure that their RMA process is efficient, compliant, and customer-centric.
An RMA form is only as effective as the return policy it supports. To maintain consistency and fairness, companies should define and clearly communicate their return policies alongside the RMA process:
A well-designed RMA form is a cornerstone of effective return management, benefiting both customers and businesses. By offering a clear and structured way for customers to initiate returns, companies can track returns accurately, reduce fraud, improve inventory management, and enhance overall customer satisfaction.
In a competitive market, the return experience can make or break customer loyalty. Continuously refining your RMA form design and return policies based on customer feedback and operational insights can lead to better outcomes for your business, and happier customers in the long run.
A request form is an online tool used to formally gather specific information or service requests from users. Request forms help streamline communication between users and organizations. When powered by Formspree, request forms are simple to embed, provide instant email notifications, and allow real-time viewing of submissions on the Formspree dashboard.
To write a request form, clearly define the information needed, such as user contact details, type of request, and any necessary additional information. Using Formspree, you can create a fully functional request form that not only collects data efficiently but also notifies your team immediately and stores responses securely for easy access.
A letter request form is used to collect information needed to generate formal letters, such as recommendation letters, employment letters, or verification letters. With Formspree as the backend, these forms can quickly capture necessary details and automatically notify the responsible party upon each submission.
A customer request form allows businesses to gather service, support, or product requests directly from customers in an organized way. Formspree-powered customer request forms simplify data collection, instantly alert your team via email, and make tracking and managing customer needs effortless through the dashboard.
Request form data refers to the information submitted by users through the request form, including names, contact details, specific requests, and additional notes. With Formspree, this data is securely stored, immediately accessible via your dashboard, and delivered to your inbox through automatic email notifications.
No pages found with the specified tag.