Error 405 when creating any record

I get Error Code 405 whenever I try to create any register or modify my user or create a company.

Please support us!

This is an example of the generated error:

405: {data: {id: VolejRejNm, company_key: NI3VXsH3Xpb5K74Of1gMmpC62ifDNsW8, update_products: true, fill_products: true, convert_products: false, custom_surcharge_taxes1: false, custom_surcharge_taxes2: false, custom_surcharge_taxes3: false, custom_surcharge_taxes4: false, show_product_cost: false, enable_product_cost: false, show_product_details: true, enable_product_quantity: true, default_quantity: true, custom_fields: {}, size_id: , industry_id: , first_month_of_year: , first_day_of_week: , subdomain: , portal_mode: subdomain, portal_domain: , settings: {auto_archive_invoice: false, qr_iban: , besr_id: , lock_invoices: off, enable_client_portal_tasks: false, show_all_tasks_client_portal: invoiced, enable_client_portal_password: false, enable_client_portal: true, enable_client_portal_dashboard: false, signature_on_pdf: false, document_email_attachment: false, portal_design_id: 1, timezone_id: 1, date_format_id: 1, military_time: false, language_id: 1, show_currency_code: false, company_gateway_ids: , currency_id: 1, custom_value1: , custom_value2: , custom_value3: , custom_value4: , default_task_rate: 0, payment_terms: , send_reminders: true, custom_message_dashboard: , custom_message_unpaid_invoice: , custom_message_paid_invoice: , custom_message_unapproved_quote: , auto_archive_quote: false, auto_convert_quote: true, auto_email_invoice: true, entity_send_time: 6, inclusive_taxes: false, quote_footer: , translations: {}, counter_number_applied: when_saved, quote_number_applied: when_saved, invoice_number_pattern: , invoice_number_counter: 1, recurring_invoice_number_pattern: , recurring_invoice_number_counter: 1, quote_number_pattern: , quote_number_counter: 1, client_number_pattern: , client_number_counter: 1, credit_number_pattern: , credit_number_counter: 1, task_number_pattern: , task_number_counter: 1, expense_number_pattern: , expense_number_counter: 1, recurring_expense_number_pattern: , recurring_expense_number_counter: 1, recurring_quote_number_pattern: , recurring_quote_number_counter: 1, vendor_number_pattern: , vendor_number_counter: 1, ticket_number_pattern: , ticket_number_counter: 1, payment_number_pattern: , payment_number_counter: 1, project_number_pattern: , project_number_counter: 1, purchase_order_number_pattern: , purchase_order_number_counter: 1, shared_invoice_quote_counter: false, shared_invoice_credit_counter: false, recurring_number_prefix: , reset_counter_frequency_id: 0, reset_counter_date: , counter_padding: 4, auto_bill: off, auto_bill_date: on_due_date, invoice_terms: , quote_terms: , invoice_taxes: 0, invoice_design_id: Wpmbk5ezJn, quote_design_id: Wpmbk5ezJn, credit_design_id: Wpmbk5ezJn, purchase_order_design_id: Wpmbk5ezJn, purchase_order_footer: , purchase_order_terms: , purchase_order_public_notes: , require_purchase_order_signature: false, invoice_footer: , credit_footer: , credit_terms: , invoice_labels: , tax_name1: , tax_rate1: 0, tax_name2: , tax_rate2: 0, tax_name3: , tax_rate3: 0, payment_type_id: 0, valid_until: , show_accept_invoice_terms: false, show_accept_quote_terms: false, require_invoice_signature: false, require_quote_signature: false, email_sending_method: default, gmail_sending_user_id: 0, reply_to_email: , reply_to_name: , bcc_email: , pdf_email_attachment: false, ubl_email_attachment: false, email_style: light, email_style_custom: , email_subject_invoice: , email_subject_quote: , email_subject_credit: , email_subject_payment: , email_subject_payment_partial: , email_subject_statement: , email_subject_purchase_order: , email_template_purchase_order: , email_template_invoice: , email_template_credit: , email_template_quote: , email_template_payment: , email_template_payment_partial: , email_template_statement: , email_subject_reminder1: , email_subject_reminder2: , email_subject_reminder3: , email_subject_reminder_endless: , email_template_reminder1: , email_template_reminder2: , email_template_reminder3: , email_template_reminder_endless: , email_signature: , enable_email_markup: true, email_subject_custom1: , email_subject_custom2: , email_subject_custom3: , email_template_custom1: , email_template_custom2: , email_template_custom3: , enable_reminder1: false, enable_reminder2: false, enable_reminder3: false, enable_reminder_endless: false, num_days_reminder1: 0, num_days_reminder2: 0, num_days_reminder3: 0, schedule_reminder1: , schedule_reminder2: , schedule_reminder3: , reminder_send_time: 0, late_fee_amount1: 0, late_fee_amount2: 0, late_fee_amount3: 0, late_fee_percent1: 0, late_fee_percent2: 0, late_fee_percent3: 0, endless_reminder_frequency_id: 0, late_fee_endless_amount: 0, late_fee_endless_percent: 0, client_online_payment_notification: true, client_manual_payment_notification: true, name: , company_logo:, website: , address1: , address2: , city: , state: , postal_code: , phone: , email: , country_id: 840, vat_number: , id_number: , page_size: A4, page_layout: portrait, font_size: 7, primary_font: Roboto, secondary_font: Roboto, primary_color: #298AAB, secondary_color: #7081e0, page_numbering: false, page_numbering_alignment: C, hide_paid_to_date: false, embed_documents: false, all_pages_header: false, all_pages_footer: false, pdf_variables: {client_details: [$, $client.number, $client.vat_number, $client.address1, $client.address2, $client.city_state_postal, $client.postal_city, $, $, $], vendor_details: [$, $vendor.number, $vendor.vat_number, $vendor.address1, $vendor.address2, $vendor.city_state_postal, $vendor.postal_city, $, $, $], purchase_order_details: [$purchase_order.number, $purchase_order.po_number, $, $purchase_order.due_date, $, $purchase_order.balance_due], company_details: [$, $company.id_number, $company.vat_number, $, $, $], company_address: [$company.address1, $company.address2, $company.city_state_postal, $company.postal_city, $], invoice_details: [$invoice.number, $invoice.po_number, $, $invoice.due_date, $, $invoice.balance_due], quote_details: [$quote.number, $quote.po_number, $, $quote.valid_until, $], credit_details: [$credit.number, $credit.po_number, $, $credit.balance, $], product_columns: [$product.item, $product.description, $product.unit_cost, $product.quantity, $, $, $product.line_total], task_columns: [$task.service, $task.description, $task.rate, $task.hours, $, $, $task.line_total], total_columns: [$net_subtotal, $subtotal, $discount, $custom_surcharge1, $custom_surcharge2, $custom_surcharge3, $custom_surcharge4, $total_taxes, $line_taxes, $total, $paid_to_date, $outstanding], statement_invoice_columns: [$invoice.number, $, $due_date, $total, $balance], statement_payment_columns: [$invoice.number, $, $method, $statement_amount]}, portal_custom_head: , portal_custom_css: , portal_custom_footer: , portal_custom_js: , client_can_register: false, client_portal_terms: , client_portal_privacy_policy: , client_portal_enable_uploads: false, client_portal_allow_under_payment: false, client_portal_under_payment_minimum: 0, client_portal_allow_over_payment: false, use_credits_payment: off, hide_empty_columns_on_pdf: false, email_from_name: , auto_archive_invoice_cancelled: false, vendor_portal_enable_uploads: false, send_email_on_mark_paid: false, postmark_secret: , mailgun_secret: , mailgun_domain: , auto_bill_standard_invoices: false, email_alignment: center, show_email_footer: true, company_logo_size: 65%}, enabled_tax_rates: 0, enabled_modules: 32767, updated_at: 1676286214, archived_at: 0, created_at: 1676283474, slack_webhook_url: , google_analytics_url: , google_analytics_key: , matomo_url: , matomo_id: , enabled_item_tax_rates: 0, client_can_register: false, is_large: false, is_disabled: false, enable_shop_api: false, mark_expenses_invoiceable: false, mark_expenses_paid: false, invoice_expense_documents: false, invoice_task_timelog: true, auto_start_tasks: false, invoice_task_documents: false, show_tasks_table: false, use_credits_payment: always, default_task_is_date_based: false, enable_product_discount: false, calculate_expense_tax_by_amount: false, hide_empty_columns_on_pdf: false, expense_inclusive_taxes: false, expense_amount_is_pretax: true, oauth_password_required: false, session_timeout: 0, default_password_timeout: 1800000, invoice_task_datelog: true, show_task_end_date: false, markdown_enabled: false, use_comma_as_decimal_place: false, report_include_drafts: false, client_registration_fields: [{key: first_name, required: true}, {key: last_name, required: true}, {key: email, required: true}, {key: phone, required: false}, {key: password, required: true}, {key: name, required: false}, {key: website, required: false}, {key: address1, required: false}, {key: address2, required: false}, {key: city, required: false}, {key: state, required: false}, {key: postal_code, required: false}, {key: country_id, required: false}, {key: custom_value1, required: false}, {key: custom_value2, required: false}, {key: custom_value3, required: false}, {key: custom_value4, required: false}, {key: public_notes, required: false}, {key: vat_number, required: false}, {key: currency_id, required: false}], convert_rate_to_client: true, markdown_email_enabled: true, stop_on_unpaid_recurring: false, use_quote_terms_on_conversion: false, stock_notification: true, inventory_notification_threshold: 0, track_inventory: false, enable_applying_payments: false, enabled_expense_tax_rates: 0, invoice_task_project: false, report_include_deleted: false, invoice_task_lock: false, convert_payment_currency: false, convert_expense_currency: false, notify_vendor_when_paid: false, invoice_task_hours: false, documents: []}}


Are you creating the company in the app or using the API?

Hi, Thank you for your reply.

I installed IV on our hosting using INSTALLATRON.

It doesn’t matter what I want to create. It always launches the error 405.

@david do you have any ideas?

HTTP 405 is method not allowed, so most likely your APP_URL is incorrect.

CleanShot 2023-02-14 at 08.48.46

I followed step by steps all the instructions, and my System is healthy, as you can see. The only thing is, I cannot create anything.

Any suggestion?

I have tried everything!

What is the full url where your app lives. Don’t include the domain name, but include the full path.

Your login route works fine, is it just the company route?


I tried several solutions, modifying public/.htaccess and root/.htaccess adding RewriteBase /

I am pretty sure the problem is with the .htaccess file

Can you confirm the docroot of your webserver is pointing to the /public folder of invoice ninja?

You’ll want to wind back those .htaccess changes.

However I am puzzled why the login route works ok, but others do not…


RewriteEngine On RewriteRule "^.env" - [F,L] RewriteRule "^storage" - [F,L] RewriteRule ^(.well-known)($|/) - [L]

RewriteBase /
RewriteRule ^(.*)$ /private/$1 [L]

server-configs-apache/.htaccess at main · h5bp/server-configs-apache · GitHub

What does this do? does the app work without this?

Sorry, that was one of many tries.

This is the one that is working right now

@david Do you know where is the mistake?


It may be easier to work backwards here, if you revert back to the default .htaccess what errors are thrown?