Features Docs Download Changelog Blog Download
Documentation

PHPTinker docs

Everything you need to go from install to running your app's real kernel in one buffer.


Install & activate

Grab the build for your platform from the download page. PHPTinker does not bundle a PHP runtime — it spawns the php binary already on your machine, so make sure you have one installed (Homebrew, Herd, Valet, or system PHP all work).

  1. Open PHPTinker and, when prompted, paste the license key from your purchase email.
  2. Activation is per-machine. Your license covers a fixed number of activations — see License & privacy.
  3. Once activated, the app works fully offline; it only re-checks the license periodically.

Your first run

Create a tab, point it at a project folder, type an expression, and press ⌘ ⏎ (Ctrl ⏎ on Windows/Linux). The last expression in the buffer is auto-dumped, REPL-style.

// Point the tab at a Laravel project, then:
User::query()->where('plan', 'pro')->count()

Output streams in as it prints — you don't wait for the script to finish.

Execution modes

PHPTinker auto-detects the right mode from the project on disk. You never pick the wrong one:

  • Raw PHP — one-off snippets with no autoloader. Fastest possible boot.
  • Composer — autoloads vendor/ for any package-using project (Symfony, Lumen, custom apps).
  • Laravel — boots bootstrap/app.php and the console kernel, so providers, facades, config, and models bind exactly as in production.

Projects & tabs

Each tab carries its own buffer, project root, output stream, and class index. Run two projects side by side without touching your shell. Tabs, buffers, and project bindings persist on disk, so quitting mid-investigation loses nothing.

Output & dumps

PHPTinker ships custom printers for the types you actually work with — Illuminate\Support\Collection, Eloquent models, DateTimeInterface, and Stringable — instead of a recursive var_dump. Exceptions are readable too: QueryException shows the offending SQL and bindings, and traces are walked through $previous.

Autocomplete

The editor is Monaco (the engine behind VS Code) and knows every class composer knows about — PSR-4 and classmaps. Start typing a class name and let it complete the fully-qualified namespace. The class index is built in the background and cached per project for 24 hours, refreshing only when composer install changes something.

AI assist

Press ⌘ K to generate or refactor code inline. PHPTinker uses a bring-your-own-key model: add your own OpenAI or Anthropic key in settings and requests go directly from your machine to that provider — no token markup, nothing logged on our side.

AI is entirely opt-in. Leave the key field blank and PHPTinker makes no AI network calls at all.

Keyboard shortcuts

  • ⌘ ⏎ — Run the current buffer
  • ⌘ K — AI assist (generate / refactor)
  • ⌘ T — New tab
  • ⌘ ⇧ K — Clear output

On Windows and Linux, use Ctrl in place of .

License & privacy

Your license activates on a set number of machines and is verified with a signed certificate that works offline for up to a week between checks. Your code, project paths, and outputs are never transmitted — the only network call is license validation, which carries just a key, a machine ID, and a version. See the privacy policy for details.