A comprehensive PHP-based personal and business accounting management system with powerful expense tracking, subscription management, and reporting capabilities.
Accounting Panel Docker Setup Script Production-ready automated deployment with secure configuration
Usage:
curl -fsSL https://raw.githubusercontent.com/moonshadowrev/PersonalAccounter/main/setup.sh | bash
wget -qO- https://raw.githubusercontent.com/moonshadowrev/PersonalAccounter/main/setup.sh | bash
git clone https://github.com/moonshadowrev/PersonalAccounter
cd PersonalAccounter
bash ./setup.sh
- Multi-method expense tracking with support for credit cards, bank accounts, and cryptocurrency wallets
- Smart categorization with tags and hierarchical organization
- Tax calculation with customizable rates and types
- Approval workflow with pending/approved/rejected/paid status tracking
- File attachments for receipts and documentation
- Bulk import/export via Excel, CSV, and JSON formats
- Recurring subscription tracking for all your services and subscriptions
- Flexible billing cycles: monthly, annual, weekly, daily, and one-time payments
- Multi-currency support with automatic calculations
- Status management: active, expired, cancelled, paused
- Cost projections and spending analysis
- Credit Cards: Full card management with bank association and currency support
- Bank Accounts: International banking with IBAN, SWIFT/BIC, and routing number support
- Crypto Wallets: Multi-network cryptocurrency wallet management with address validation
- Real-time dashboard with comprehensive financial statistics
- Visual analytics with charts and graphs for spending patterns
- Date-filtered reports for any time period
- Export capabilities in multiple formats (CSV, JSON, Excel)
- Category and payment method breakdowns
- Two-Factor Authentication (2FA) with Google Authenticator support
- User role management (admin, superadmin)
- API key management with permission-based access control
- CSRF protection and security headers
- Session security with configurable timeouts
- RESTful API with OpenAPI/Swagger documentation
- Authentication via API keys or Bearer tokens
- Rate limiting and comprehensive error handling
- Webhooks support for external integrations
- Comprehensive endpoints for all application features
Comprehensive financial overview with real-time statistics, recent transactions, and spending analytics
Intuitive expense tracking interface with category management, bulk operations, and advanced filtering
Detailed financial reports with visual charts, spending patterns, and exportable data insights
User management, security settings, API configuration, and system administration tools
- PHP: 8.0 or higher
- MySQL: 5.7 or higher
- Web Server: Apache or Nginx
- Composer: For dependency management
pdo_mysql
json
openssl
mbstring
gd
curl
zip
git clone https://github.com/moonshadowrev/PersonalAccounter
cd PersonalAccounter
composer install
cp .env.example .env
Edit the .env
file with your configuration:
# Application
APP_ENV=production
APP_DEBUG=false
APP_URL=https://your-domain.com
APP_DOMAIN=your-domain.com
APP_TIMEZONE=UTC
# Database
DB_HOST=localhost
DB_NAME=personal_accounter
DB_USER=your_username
DB_PASS=your_password
DB_PORT=3306
# Security
SESSION_LIFETIME=0
SESSION_SECURE=true
SESSION_SAMESITE=Lax
LOGIN_ATTEMPTS_LIMIT=5
LOGIN_ATTEMPTS_TIMEOUT=300
# API
API_MAX_FAILED_ATTEMPTS=5
API_BLOCK_DURATION=300
API_DEFAULT_RATE_LIMIT=60
API_MAX_RATE_LIMIT=1000
# Logging
LOG_CHANNEL=file
LOG_LEVEL=warning
LOG_MAX_FILES=5
# Run migrations
php control migrate run
# Create admin user
php control user admin
# Seed with sample data (optional)
php control db seed
chmod 755 -R .
chmod 777 -R logs/
chmod 777 -R sessions/
chmod 777 -R public/uploads/
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ public/index.php [QSA,L]
location / {
try_files $uri $uri/ /public/index.php?$query_string;
}
location ~ \.php$ {
fastcgi_pass unix:/var/run/php/php8.0-fpm.sock;
fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
include fastcgi_params;
}
Navigate to https://your-domain.com
and log in with your admin credentials.
- Go to Payment Methods β Bank Accounts
- Add your bank account information
- Add credit cards and crypto wallets as needed
- Go to Expenses β Categories
- Create categories for your expense types (Food, Transport, Utilities, etc.)
- Use the "Create Defaults" button to add common categories
- Go to Expenses β All Expenses
- Click "Add Expense"
- Fill in the details and submit
- Go to Subscriptions
- Add your recurring services and subscriptions
- Set billing cycles and amounts
- Create: Add new expenses with detailed information including tax calculations
- Categorize: Organize expenses using categories and tags
- Approve: Use the approval workflow for business expense management
- Import: Bulk import expenses from Excel or CSV files
- Export: Generate reports in various formats
- Add Services: Track all your recurring subscriptions
- Monitor Costs: View monthly and annual cost projections
- Status Management: Mark subscriptions as active, paused, expired, or cancelled
- Billing Cycles: Support for various billing frequencies
- Dashboard: View comprehensive financial overview
- Date Filtering: Generate reports for specific time periods
- Visual Analytics: Charts and graphs for spending patterns
- Export Options: CSV, JSON, and Excel format exports
The application includes a powerful CLI tool:
# Database migrations
php control migrate run
php control migrate fresh
php control migrate rollback
php control migrate status
# User management
php control user create "John Doe" "john@example.com" "password" "admin"
php control user list
php control user delete "john@example.com"
php control user admin
# Database operations
php control db seed
php control db reset
php control db status
# Fake data generation
php control faker all
php control faker generate --users=10 --expenses=100
# Get API key from Profile β API Keys in the web interface
curl -H "X-API-Key: your-api-key" https://your-domain.com/api/v1/expenses
# Get all expenses
curl -H "X-API-Key: your-key" https://your-domain.com/api/v1/expenses
# Create an expense
curl -X POST -H "X-API-Key: your-key" \
-H "Content-Type: application/json" \
-d '{"title":"Lunch","amount":25.50,"category_id":1}' \
https://your-domain.com/api/v1/expenses
# Get dashboard statistics
curl -H "X-API-Key: your-key" https://your-domain.com/api/v1/reports/dashboard
Access the interactive API documentation at:
- Swagger UI:
https://your-domain.com/api/docs/ui
(development mode only) - OpenAPI JSON:
https://your-domain.com/api/docs
(development mode only)
PersonalAccounter/
βββ app/
β βββ Controllers/ # Application controllers
β βββ Models/ # Database models
β βββ Services/ # Business logic services
β βββ Routes/ # Route definitions
β βββ Views/ # Template files
βββ bootstrap/ # Application bootstrap
βββ config/ # Configuration files
βββ database/ # Database migrations
βββ logs/ # Application logs
βββ public/ # Web accessible files
βββ sessions/ # Session storage
βββ vendor/ # Composer dependencies
- Backend: PHP 8.0+ with custom MVC framework
- Database: MySQL with Medoo ORM
- Frontend: HTML5, CSS3, JavaScript (Vanilla JS)
- Authentication: Custom session-based auth with 2FA
- API: RESTful with OpenAPI documentation
- Security: CSRF protection, XSS prevention, input validation
The application supports multiple currencies and international banking:
- Currencies: USD, EUR, GBP, CAD, AUD, JPY, CHF, CNY, SEK, NOK, DKK, SGD, HKD
- Banking: IBAN and SWIFT/BIC support for international accounts
- Crypto: Multi-network cryptocurrency support
PersonalAccounter implements comprehensive security measures:
- CSRF Protection: All forms protected against cross-site request forgery
- XSS Prevention: Input sanitization and output encoding
- SQL Injection: Prepared statements and parameterized queries
- Session Security: Secure cookie settings and session regeneration
- Rate Limiting: API and login attempt limitations
- Security Headers: HSTS, content type options, frame options
- Two-Factor Authentication: Google Authenticator integration
For detailed documentation including:
- API Reference: Complete endpoint documentation
- Security Guide: Security implementation details
- Contribution Guidelines: How to contribute to the project
- Feature Wiki: Detailed feature documentation
See the docs/
directory.
This project is licensed under the GNU General Public License v3.0 (GPL-3.0).
See LICENSE for the full license text.
We welcome contributions! Please see CONTRIBUTING.md for guidelines.
- Bug Reports: GitHub Issues
- Feature Requests: GitHub Discussions
- Security Issues: See SECURITY.md
See CHANGELOG.md for version history and changes.
PersonalAccounter - Take control of your finances with powerful, secure, and flexible accounting management.