Enjoying the docs? Start building free, no credit card needed. Get started →
Docs / Laravel

Web

Laravel

Add a feature request board to your Laravel app. One package, one env var, one Blade tag.

Needs PHP 8.2 or later and Laravel 10, 11, 12 or 13. No JavaScript build step and no Tailwind needed.

Install

  1. Add the package

    composer require fewchurs/laravel
  2. Publish the config

    php artisan fewchurs:install
  3. Add your API key

    Use the key from your dashboard. It goes in .env, never in your code.

    .env
    FEWCHURS_API_KEY=fr_live_xxx

Show the board

That's already done: the package adds a ready-made page at /feedback. Open it and you'll see your board with Top and New tabs, voting, comments and a form for new requests.

To put the board inside one of your own pages, add the Blade tag anywhere:

<x-fewchurs::board />

It's rendered on your server, so voting and commenting work even with JavaScript turned off. If your app uses Livewire, there's a reactive version too:

<livewire:fewchurs-board />

Votes count the moment someone clicks, and save in the background. If the API can't be reached, the board shows a short message with a "Try again" button inside the board, and the rest of your page keeps working.

Add lazy to the Livewire board to show a loading shimmer until it's ready:

<livewire:fewchurs-board lazy />

As a sheet

Put the board behind a floating button instead of on the page. Add it once, for example to your main layout, and it shows on every page:

<x-fewchurs::sheet />                    {{-- slides in from the right --}}<x-fewchurs::sheet side="left" /><x-fewchurs::sheet side="bottom" />

The sheet opens on your list of requests. A floating New request button switches it to the form and Back returns to the list.

Change the button text with label:

<x-fewchurs::sheet label="Suggest a feature" />

Or hide the floating button and open the sheet from any element of your own with data-fewchurs-open:

<x-fewchurs::sheet :trigger="false" /><button data-fewchurs-open>Feedback</button>

The board loads only the first time the sheet opens, so pages where nobody opens it make no API calls. On phones it fills the screen, and without JavaScript the button is a link to /feedback.

The sheet shows /feedback in a frame, so it needs that route. If your app sends X-Frame-Options: DENY or a CSP frame-ancestors 'none', allow your own site to frame /feedback.

Use your own layout

To render /feedback inside your app's layout, with your header and footer, set these in config/fewchurs.php:

config/fewchurs.php
'board' => [    'layout' => 'layouts.app',  // your layout view    'section' => 'content',     // the @yield it renders into],

The same file sets the URL prefix, which tabs show, how many requests per page, whether comments and following are open, whether the email field is hidden, optional or required, and whether people must be signed in to post.

Customize

Change the color and corner radius right on the tag:

<x-fewchurs::board :theme="['primary' => '#ED5F18', 'radius' => '12px']" />

Add your own heading above the board with a slot:

<x-fewchurs::board>    <x-slot:header>        <h1>Help shape {{ config('app.name') }}</h1>    </x-slot:header></x-fewchurs::board>

To change the markup or the wording, publish the views and translations. They're small Blade and lang files, made to be edited:

php artisan vendor:publish --tag=fewchurs-viewsphp artisan vendor:publish --tag=fewchurs-lang

Build your own UI

Prefer your own design? Use the PHP client and render it however you like. Every call throws a typed exception on failure, with a userMessage() that's safe to show.

use Fewchurs\Laravel\Facades\Fewchurs;$page = Fewchurs::features()->top(limit: 20);$feature = Fewchurs::features()->submit(    title: 'Add dark mode',    description: 'Would love a dark theme.',    email: auth()->user()?->email,);Fewchurs::features()->vote($feature->id);Fewchurs::comments()->create($feature->id, text: '+1');

The package README covers everything else: visitor identity, more than one board, events, and Fewchurs::fake() for your tests.

Check your setup

One command tells you whether your key works and the board can be reached:

php artisan fewchurs:check

After a deploy, php artisan fewchurs:warm loads the board settings ahead of the first visitor.

Localhost and going live

Your API key only works from the domain you add to your app. Laravel handles this for you. It sends the domain each page is opened on with every request, so the key works on your live domain whatever APP_URL says. This needs version 1.8.0 or later.

While you build on localhost

You only need your API key. There is nothing to add in the dashboard yet.

.env
APP_URL=http://localhost:8000FEWCHURS_API_KEY=fr_live_xxx

localhost and 127.0.0.1 always work. While APP_DEBUG=true the board shows a small note to remind you to add your domain before you go live. Visitors never see this note.

When you go live

  1. Open your app in the Fewchurs dashboard.

  2. Under Where does your app run? pick Web.

  3. Add just the domain in Website domain, like yourcompany.com. Leave out https://.

  4. Click Save changes. A new domain can take up to a minute to work.

  5. Set these in the .env on your live server:

    .env
    APP_URL=https://yourcompany.comAPP_DEBUG=falseFEWCHURS_API_KEY=fr_live_xxx

    The board doesn't use APP_URL, but php artisan fewchurs:check does. A command has no visitor, so it sends the domain in APP_URL instead.

  6. If you cache your config, refresh it:

    php artisan config:cache
  7. Check it on your live server:

    php artisan fewchurs:check

    You should see "Board reachable".

Don't skip the domain. The board can work on localhost and still be refused on your live site if your domain isn't added.

Test your domain before you go live

You can check your domain from localhost:

  1. Add this line to your local .env:

    .env
    FEWCHURS_APP_ID=yourcompany.com
  2. Run these:

    php artisan config:clear
    php artisan fewchurs:check

If you see "Board reachable" your domain is set up. Remove the line when you're done. If you only just added the domain and it's refused, wait a minute and run the check again.

Which addresses work

If you add yourcompany.com:

Page opened onResult
http://localhost:8000Works
https://yourcompany.comWorks
https://www.yourcompany.comWorks
https://app.yourcompany.comWorks
https://othercompany.comRefused

Subdomains of the domain you add work on their own. It doesn't work the other way: if you add app.yourcompany.com then yourcompany.com is refused. Add the main domain if you use more than one.

When you need FEWCHURS_APP_ID

Most sites don't need it. It sends one fixed ID instead of the domain each page is opened on, for every page and for fewchurs:check. Use it when your site runs on an address you haven't added, for example a staging site on your host's own domain:

.env
FEWCHURS_APP_ID=yourcompany.com

If you have more than one board you can give each one its own ID in config/fewchurs.php:

config/fewchurs.php
'apps' => [    'docs' => [        'api_key' => env('FEWCHURS_DOCS_KEY'),        'app_id' => 'docs.yourcompany.com',    ],],

If something goes wrong

What you seeWhat it meansWhat to do
This API key is not set up for yourcompany.com. Add it to your app in the Fewchurs dashboard.This domain isn't added to the app for this keyAdd the domain in the dashboard. The message names the domain the page was opened on. In fewchurs:check it comes from APP_URL, or from FEWCHURS_APP_ID if you set it.
Invalid API key. Check the key in your Fewchurs dashboard.The key is wrong or no longer activeCopy the key from the dashboard into .env.
Couldn't reach the feedback service.Your server can't reach FewchursCheck your server's internet connection.
Something went wrong. Try again.Any other errorSet APP_DEBUG=true on a test site to see the real cause, and check your log file.

Visitors see these messages on your live site too. Keep APP_DEBUG=false there, as Laravel recommends.

After you change .env run php artisan config:clear, or php artisan config:cache if you cache your config. The board keeps a recent copy of the list, so it can show old requests for a while after a key is refused. Run php artisan cache:clear to see the current state. php artisan fewchurs:check always checks live.

What your plan changes

Your plan is applied on our servers, so you never need to change code or update the package when it changes. Changes show up within 5 minutes.

FreeStarterPro
Requests the board listsFirst 5First 200All
"Powered by Fewchurs" lineShownHiddenHidden

Newer requests are still saved and show in your dashboard. Once your app is past its limit, a new request is accepted but doesn't appear in the board's list. See pricing.

About the API key

Here the key stays on your server: the browser only ever talks to your own Laravel routes. The package keeps it out of the page and out of your logs. Still, keep it in .env and out of git.

Each visitor gets a random ID in a cookie (or their user ID when they're signed in), hashed with your APP_KEY before it's sent. That is how votes are remembered without an account. Read more in How it works.