- How do I install arukompas/better-log-viewer in a Laravel app?
- Install it with Composer using composer require arukompas/better-log-viewer. The package registers itself through a Laravel service provider, so no manual provider registration is required, and there are no migrations or external services to configure. You can optionally publish its config file to customize the route and other options. After that, browse to the configured route to view logs from storage/logs.
- Which Laravel and PHP versions does better-log-viewer support?
- The package targets the Laravel 8, 9, and 10 era of framework conventions, based on its age and archived status. There is no active maintainer validating it against newer Laravel releases, so version drift is a real, unmitigated risk. Check the composer.json constraints on the repository and test against your exact Laravel and PHP versions before adopting it. If your target version falls outside that envelope, treat compatibility as unproven rather than assumed.
- Is arukompas/better-log-viewer safe to expose in production?
- Not by default. A route that lists and paginates raw log contents is effectively a data-exfiltration endpoint if it is reachable without authentication. You must gate it behind auth or can middleware, and ideally an IP allowlist or environment guard, before it goes anywhere near production. That authorization layer is the integrator's responsibility, not something the package enforces for you. Many teams restrict it to local or staging environments only.
- How do I secure the log viewer route with middleware?
- The package exposes its UI at a configurable route, so the practical approach is to wrap that route in your own middleware group. Apply auth, a can gate, or a custom middleware that checks the environment and client IP before allowing access. If the package's config does not let you attach middleware directly, define the route yourself in a service provider or route file and point it at the package controller. Treat this gate as a hard prerequisite, not an optional hardening step.
- Does better-log-viewer support multiple log files and daily log rotation?
- Yes, the package is designed to browse multiple log files rather than a single laravel.log. It reads Laravel's native log files from storage/logs, so daily and single-file channels are the expected use case. However, because the project is archived and thinly used, non-default channels, JSON-formatted logs, and multi-line exception traces are unlikely to have been broadly exercised. Test your specific channel and rotation setup before relying on it.
- Can I search and filter logs by level in better-log-viewer?
- Yes. Searching log contents and filtering by level are core features, alongside pagination for browsing results. This is the main improvement over raw tail and grep, especially in environments where shell access is awkward. Keep in mind that search runs over file contents, so behavior on very large logs should be measured rather than assumed.
- How does better-log-viewer perform on large log files?
- This is a genuine unknown. The package advertises a speedy interface, but it parses log files rather than querying a structured store, so memory behavior on a 500 MB file is not documented and has not been widely reported given the small user base. Benchmark it against your real log sizes before depending on it. If it reads entire files into memory, it can impact the same application it is meant to help debug.
- Is arukompas/better-log-viewer still maintained?
- No. The repository is archived, which means there is no upstream to ship security patches, no maintainer to fix parsing edge cases, and no one to address Laravel compatibility breakage. The low star count also signals a very thin user base, so undocumented edge cases are unlikely to have been tested in the wild. If you adopt it, decide up front whether it is a temporary stopgap or something you are prepared to fork and own.
- What are alternatives to better-log-viewer for Laravel?
- Most teams already have tail and grep over SSH, Laravel Telescope, Laravel Pulse, Sentry, or a centralized log aggregator. The honest positioning for this package is a browsable, searchable log UI for environments where shell access is awkward, not a replacement for observability tooling. If your organization already ships logs to a central platform, this adds marginal value and a net-new attack surface. Choose it for convenience, not for monitoring coverage.
- How do I remove better-log-viewer cleanly, and can I pilot it safely?
- Removal is zero-friction: drop the Composer dependency and delete the published config file. There is no schema, no stored data, and no background process, so nothing dangles behind. That clean reversibility is the strongest argument for a contained pilot behind strict middleware rather than a broad rollout. Pilot it in a non-production environment first and confirm log format and performance behavior before promoting it.