Tested Updated Trending Bestseller Perfect rating Documented

Cost of Goods for WooCommerce

(2 customer reviews)

From: $29.99 / year

Save WooCommerce products purchase costs.

Clear

Description

With Cost of Goods for WooCommerce plugin you can save WooCommerce products purchase costs.

After enabling the plugin, new “Cost (excl. tax)” input field will be added to the product’s edit page.

Cost of Goods for WooCommerce - Simple Product Cost Input

For variable products you can either set single cost for all variations:

Cost of Goods for WooCommerce - Variable Product Cost Input

or set costs for each variation individually:

Cost of Goods for WooCommerce - Variation Product Cost Input

Cost of Goods Plugin Options

Plugin options are located in “WooCommerce > Settings > Cost of Goods”.

Admin Orders List Columns

This section lets you add custom columns to WooCommerce admin orders list.

Cost of Goods for WooCommerce - Admin Orders List Columns

Order cost
Displays pre-calculated order total cost.
Default: no
Order cost: Order statuses
Select order statuses to show cost column. Leave empty to show for all orders.
Default: None
Order profit
Displays pre-calculated order profit.
Default: yes
Order profit: Order statuses
Select order statuses to show profit column. Leave empty to show for all orders.
Default: None

Admin Order Meta Box

Cost of Goods for WooCommerce - Admin Order Meta Box

Order meta box
Displays “Cost of Goods” meta box on admin order edit page.
Default: yes

Cost of Goods for WooCommerce - Admin Order Meta Box - Order Page

Admin Products List Columns

This section lets you add custom columns to WooCommerce admin products list.

Cost of Goods for WooCommerce - Admin Products List Columns Options

Product cost
Displays product cost.
Default: no
Product profit
Displays product profit.
Default: no

Reports

Orders Report

Cost of Goods orders report is available in “Reports > Orders > Cost of Goods”.

Cost of Goods for WooCommerce - Orders Report

Stock Report

Cost of Goods stock report is available in “Reports > Stock > Cost of Goods”.

Cost of Goods for WooCommerce - Reports - Stock

Bulk Edit Costs Tool

Bulk edit tool is located in “Tools > Bulk Edit Costs”. Use it if you need to bulk edit costs for all products from a single page.

Cost of Goods for WooCommerce - Bulk Edit Costs Tool Options

Search products
Possible values: Search by title; Search all.
Default: Search by title
Edit prices
Enable this if you want to edit product prices in addition to cost of goods.
Default: no
Manage stock
Enable this if you want to manage products stock in addition to cost of goods.
Default: no
Manage stock: Stock update method
Ignored unless “Manage stock” checkbox is enabled above. Possible values: Update product meta; Use product functions.
Default: Update product meta

Cost of Goods for WooCommerce - Bulk Edit Costs Tool

Import Costs Tool

Import tool is located in “Tools > Import Costs”. Use it if you need to import costs from other meta fields.

Cost of Goods for WooCommerce - Import Costs Tool Options

Key to import from
Meta key to import costs from.
Default: _wc_cog_cost

Cost of Goods for WooCommerce - Import Costs Tool

Orders Tools

Cost of Goods for WooCommerce - Orders Tools Options

Recalculate orders cost and profit for all orders
Set items costs in all orders (overriding previous costs). Enable the checkbox and save changes to run the tool.
Default: no
Recalculate orders cost and profit for orders with no costs
Set items costs in orders that do not have costs set. Enable the checkbox and save changes to run the tool.
Default: no

2 reviews for Cost of Goods for WooCommerce

  1. numanzahid (verified owner)

    Great Plugin. Really what I needed.

  2. benye

    Great plugin! Great support!

Add a review

Your email address will not be published. Required fields are marked *

44 thoughts on "Cost of Goods for WooCommerce"

  1. Hey,

    I can’t manage to bulk edit cost prices.
    can you please advise how to do so?

    Thanks,
    Reef.

    1. Hi,

      Sorry for the late reply.

      Generally, our tool is located in “Tools > Bulk Edit Costs” in your admin area, but, I suppose, you already checked that? Are you having any issues? If so – are there any (error) messages?

  2. Hi Tom,

    I just wondered if this is compatible with WooCommerce 4.0?

    Thanks, Keith

    1. Hi Keith,

      As far as I tested everything is working fine with WC 4.0.

    2. Hi,

      I cannot add any more costs in the bulk edit section.
      I type them in, click save all and nothing saves?

    3. It worked for the first 430 or so but wont save for any after that

    4. Hi Samuel,

      Maybe it would be possible for me to log in to your site to check it out? And FTP access would also help. How many products do you have on your site?

      Just to be sure – is your question related to the original Keith’s thread about the compatibility with WooCommerce v4.0?

  3. Hi Tom,
    I have an issue – only maybe related to your plugin,
    All worked fine and all plugins are up to date, but suddenly, when setting regular price to all variation to a new product, we need to verify twice about saving changes but most times only some or none of the variations get update with the price, same for sale price, and only when cancelling the request to save changes the prices get updated. and I think (humbly) its related to the cost of goods plugin cause before we had it install in the past we did not get requested to save changes when setting regular price.
    do you think its related to you?
    If im wrong – sorry to bother.
    Thanks,

    1. Hi Lior,

      Could you please let me know if the issue is still there if you disable our plugin?

    2. Hi Tom,

      When disabling your plugin the issue is fixed.

    3. Hi Lior,

      Ok. Could you please try disabling “Prepopulate in AJAX” and then “Repopulate on recalculate” options in plugin settings and let me know if disabling any of them makes any difference?

    4. Hi Tom,

      I disabled “Prepopulate in AJAX” that was already checked, and the issue is still there,
      “Repopulate on recalculate” was already disabled, so I didn’t enable it.
      Maybe I can try something else?
      Thx

    5. Hi Lior,

      Hmm… Maybe I can log in to your site to check it out (my email is [email protected])? And just to be sure – you are using the latest plugin v1.4.5?

  4. In case payment is not made at the time of purchase the same cost and profit are showing for previous order in the orders list as well.
    After another order is made and paid, then cost and profit are showing up correctly for all orders again.

    1. Hi Kristjan,

      Maybe it would be possible for me to log in to your site to check what’s going on (my email is [email protected])? Please let me know if sharing an account is not an option and I will continue solving it remotely.

    2. If anyone else has a similar issue – this is fixed in plugin v1.4.6.

  5. Hi its not showing right amount of profit and cost. My total sales are 4k$+ but its only showing 642$ cost and 664$ profit in THIS MONTH tab and for year with 7k$ sales its showing only 2.1k$ cost and 1840$ Profit. Kindly help me fix this issue

    https://prnt.sc/r7hvg4

    1. Hi,

      The first idea that comes to mind – did you click “Recalculate orders cost and profit for all orders” (in “WooCommerce > Settings > Cost of Goods > Tools”) so the plugin would calculate profits from before it was installed? Also please make sure that you have set costs for the products from the orders.

      If that doesn’t help – as far as I remember, WooCommerce saves reports in transients, so please try clearing transients in “WooCommerce > Status > Tools > WooCommerce transients”.

      If none of the above helps – maybe it’s possible for me to log in to your site to check what’s going on (my email is [email protected])? Please let me know if sharing an account is not an option and I will continue solving it remotely.

    2. I’ve tried doing both of the things above but its still not giving me the whole amount.

      My total sales are 666$ this month. Its showing me 605$ total after i add cost and profit.

      https://prnt.sc/raxfm5

      332$+272$ = 605$ however the amount of total sales are 666$
      All the products have their cost and profit on orders page from this month.

    3. Hi,

      The only explanation I’ve got – some order items (i.e. products) do not have the cost entered. Even if an order has profit calculated, it may be that some items don’t have cost set. For example, let’s say we have an order with a total of $100. Let’s say this order has two items: Product A and Product B, both sold for $50. Now if you have only set cost for Product A (let’s say $30), then the order profit will show $20, so that can produce a mismatch.

      Again, if I could log in, I would be able to tell exactly what’s happening. I would start by checking reports day by day (i.e. instead of “This month”, I would start checking “2020-03-01 – 2020-03-01”, “2020-03-02 – 2020-03-02” and so on, until I could see a mismatch, then I would check each order for that day.

  6. Hi,

    I’ve unticked Admin Order Options -> Meta box
    Adds “Cost of Goods” meta box to admin order edit page.

    but the Cost of Goods box is still showing on all orders.

    I would like to remove it.

    Can you help?

    1. Hi Keith,

      Hmm… That’s really strange. I’ve just retested it on my server and it seems to be working fine here – as soon as I unchecked the “Meta box” checkbox, the “Cost of Goods” meta box on the order edit page is no longer showing. Are you sure it’s not coming from some other cost of goods plugin? Maybe I can log in to your server to check what’s going on (my email is [email protected])?

    2. In case if anyone else has a similar issue – the question was about item cost inputs (i.e. not about the meta box, which is working normally). Since plugin v1.4.5, it’s now possible to disable (or alternatively make them read-only) item cost inputs with the “Item costs” option in “WooCommerce > Settings > Cost of Goods > Admin Order Options”.

    3. Sorry for the confusion and thanks for adding the new feature Tom. Great support.

  7. how is this possible?
    order total € 64,75 – cost € 40 – profit = -€25,05 ?? see https://nimb.ws/p1aL7I

    1. Hi,

      Are there any shipping costs included in the order total? If so – please let me know what are they. Also is this order total include taxes? If so – please let me know what is tax percent.

    2. Yes shipping cost are 4.9 and inclbtax 21%.
      Looks like he don’t counts the amounts of the products but only the single product

    3. Hmm… It should count the amount… Maybe it’s possible for me to log in to your site to check what’s going on (my email is [email protected])? Please let me know if sharing an account is not an option and I will try to solve this remotely.

    4. Tom, can you check our admin, shopify plugin is updated but if you see /post.php?post=6785&action=edit there is a negative profit 🙁

  8. Hello,

    When we are trying to add variation to existing variable product (with cost of goods already entered) –
    the page stuck and the product is not editable anymore and needs to be deleted
    here is a error message I get from wordpress:

    אירעה שגיאה מסוג E_ERROR בשורה 176 בקובץ /home/thethirdeyeco/public_html/wp-content/plugins/cost-of-goods-for-woocommerce/includes/class-alg-wc-cost-of-goods-core.php. הודעת שגיאה: Uncaught Error: Call to a member function get_parent_id() on bool in /home/thethirdeyeco/public_html/wp-content/plugins/cost-of-goods-for-woocommerce/includes/class-alg-wc-cost-of-goods-core.php:176
    Stack trace:
    #0 /home/thethirdeyeco/public_html/wp-content/plugins/cost-of-goods-for-woocommerce/includes/class-alg-wc-cost-of-goods-core.php(206): Alg_WC_Cost_of_Goods_Core->get_product_cost(10268)
    #1 /home/thethirdeyeco/public_html/wp-content/plugins/cost-of-goods-for-woocommerce/includes/class-alg-wc-cost-of-goods-core.php(237): Alg_WC_Cost_of_Goods_Core->get_product_profit(10268)
    #2 /home/thethirdeyeco/public_html/wp-content/plugins/cost-of-goods-for-woocommerce/includes/class-alg-wc-cost-of-goods-core.php(219): Alg_WC_Cost_of_Goods_Core->get_variable_product_html(2780, ‘profit’)
    #3 /home/thethirdeyeco/public_html/wp-content/plugins/cost-of-goods-for-woocommerce/includes/class-alg-wc-cost-of-goods-core.php(270): Alg_WC_Cost_of_Goods_Core->get_product_profit_html(2780)
    #4 /home/thethirdeyeco/public_html/wp-incl

    Please help

    1. Hi Lior,

      Please give me a minute to check this – I will get back to you shortly.

    2. Hi again,

      I was unable to reproduce the issue on my server, however, I’ve just released new plugin version 1.4.1, where I’ve added additional safe-checks to the code. Could you please update and let me know if this fixes the issue.

    3. Hi Tom,

      Sorry for my late reply, Yes the update solve the issue, thanks!!!

    4. Hi Lior,

      Great, happy to hear it’s solved. Please let me know if you need anything else. And if you like the plugin, please consider leaving me a rating.

  9. Bonjour, je viens d’installer le plugin Cost of good pro, mais je ne comprends pas la logique du calcul, mon “cost(excl.tax) donc mon prix HT + le “profit” n’est pas égal a mon prix ttc, certe j’ai en plus de la TVA une marge, mais du coup ça fausse le profit.. ou alors je n’ai rien compris XD
    Possible d’avoir un mail ou un numéro pour m’aider a installer et a comprendre ce plugin SVP?
    Merci
    Cordialement.

    1. Hi,

      Maybe you could give me an example? I mean what is the product’s price, what cost did you set for it, and what profit is calculated by our plugin? Please note that all calculations are done excluding tax.

      Also – if you wish – you can share an admin account to your site so I could log in and check what’s going on (my email is [email protected]).

  10. Hello,

    when am adding a product to order, the cost of goods does not filled, and the system did not calculate the profit. I must add the cost manually.

    http://www.preklady-textu.cz/crm/preview/cost-of-good-error.png

    Thanks

    1. Hi Hani,

      Would it be possible for me to log in to your site’s admin, if yes – my email is [email protected]

  11. Hello

    I am getting this error in my site http://prntscr.com/p8zxgf

    1. Hi Daniel,

      Thanks for reporting. I’m not getting the error on my test server, however, I will add some more safety checks to the code to make this error impossible. Will be releasing new plugin version later today.

    2. Hi again Daniel,

      We’ve just released new plugin version 1.3.5. Could you please update and let me know if the warning is gone?

  12. hi there

    cost of good is showing up in invoice. can you please help me solve this problem. I am using this plugin for invoices. https://wordpress.org/plugins/print-invoices-packing-slip-labels-for-woocommerce/

    1. Hi,

      Sorry for the late reply.

      I’ve just added the compatibility with “WooCommerce PDF Invoices, Packing Slips, Delivery Notes & Shipping Labels” plugin in v1.3.4.

Leave a Reply

Your email address will not be published. Required fields are marked *

Changelog

1.5.0 - 08/04/2020

  • Dev - "Extra Payment Gateway Costs" section added.
  • Dev - "Extra Shipping Method Costs" section added.
  • Dev - "Order Extra Cost" subsection added.
  • Dev - Showing "N/A" (instead of empty string) when profit can not be calculated (i.e. when product cost is empty).

1.4.8 - 01/04/2020

  • Dev - Product profit - Showing profit percent for variable products now.
  • Tested up to: 5.4.

1.4.7 - 27/03/2020

  • Fix - Tools - "plugin settings" links fixed.
  • Fix - Admin settings notices fixed.
  • Dev - Admin settings descriptions updated.
  • readme.txt description updated.
  • WC tested up to: 4.0.

1.4.6 - 09/03/2020

  • Dev - Admin Orders List Columns and Admin Products List Columns - Getting order/product ID from filter params now (i.e. instead of get_the_ID()).

1.4.5 - 18/02/2020

  • Fix - Admin Order Options - Admin notice - Now showing on single order edit page only.
  • Dev - Admin Order Options - "Item costs" option added.

1.4.4 - 18/02/2020

  • Fix - Admin Order Options - Repopulate on recalculate - check_ajax_referer() bug fixed.
  • Dev - Admin Order Options - "Admin notice" options added.
  • Dev - Settings - Tools - Descriptions updated.

1.4.3 - 03/02/2020

  • Dev - Admin Order Options - "Repopulate on recalculate" option added (defaults to no).

1.4.2 - 28/01/2020

  • Dev - Admin Order Options - "Prepopulate in AJAX" option added (defaults to yes).
  • Dev - Settings - "Admin Order Meta Box" subsection renamed to "Admin Order Options".
  • Dev - Minor code refactoring.
  • WC tested up to: 3.9.

1.4.1 - 21/01/2020

  • Dev - Additional safe checks added when getting product cost from parent product.
  • Dev - Code refactoring.

1.4.0 - 24/12/2019

  • Dev - "Admin Order Meta Box" option added.
  • Dev - Tools - Bulk Edit Costs - "Edit prices" option added.
  • Dev - Tools - Bulk Edit Costs - "Search products" option (and "Search all" value) added.
  • Dev - Admin settings split into sections ("General" and "Tools").
  • Dev - Code refactoring.
  • Tested up to: 5.3.
  • WC tested up to: 3.8.

1.3.6 - 02/10/2019

  • Dev - Tools - Bulk Edit Costs - Manage stock - "Stock update method" option added.

1.3.5 - 23/09/2019

  • Dev - Reports - Additional safe checks added (to avoid possible PHP warnings on some servers).

1.3.4 - 06/09/2019

  • Dev - Tools - Bulk Edit Costs - Better styling (modified row).
  • Dev - "WooCommerce PDF Invoices, Packing Slips, Delivery Notes & Shipping Labels" plugin compatibility.
  • WC tested up to: 3.7.

1.3.3 - 04/08/2019

  • Fix - Tools - Bulk Edit Costs - Search by product title - Now searching in any part of the title (not only from the beginning).
  • Dev - Tools - Bulk Edit Costs - Better styling (active row).
  • Dev - Tools - Bulk Edit Costs - Manage stock - Trailing zeros removed from stock input.

1.3.2 - 08/07/2019

  • Dev - Tools - Bulk Edit Costs - "Search by product title" input added.
  • Dev - Tools - Bulk Edit Costs - "Stock" column added. "Manage stock" option added.
  • Dev - Tools - Bulk Edit Costs - "Price" column added.
  • Dev - Tools - Bulk Edit Costs - Restyling and minor code refactoring.
  • Dev - Reports - "Stock > Cost of goods" report added.

1.3.1 - 26/06/2019

  • Dev - Admin Orders List Columns - "Order statuses" options added.

1.3.0 - 18/06/2019

  • Dev - "Cost of goods" report added (to "Reports > Orders").

1.2.0 - 17/05/2019

  • Dev - Tools - "Bulk Edit Costs" tool added.
  • Dev - Admin settings descriptions updated etc.
  • Dev - Minor code refactoring.
  • WC tested up to: 3.6.
  • Tested up to: 5.2.

1.1.1 - 19/12/2018

  • Fix - Core - add_cost_input_shop_order() - Getting order on AJAX correctly now.

1.1.0 - 06/12/2018

  • Fix - Comma decimal separator bug fixed.
  • Dev - Profit in percent added to profit HTML output.
  • Dev - Cost meta changed from _alg_cost to _alg_wc_cog_cost.
  • Dev - Forcing cost of goods to be always set excluding taxes.
  • Dev - Saving costs as order item meta.
  • Dev - Saving total cost and profit as order meta.
  • Dev - Import Costs Tool - Code optimized.
  • Dev - Major code refactoring.
  • Dev - Plugin URI updated.
  • Pro - Dev - "Recalculate orders cost and profit for all orders" option added.
  • Pro - Dev - "Recalculate orders cost and profit for orders with no costs" option added.

1.0.1 - 17/05/2018

  • Fix - Cost not saved for simple products - bug fixed.
  • Fix - Admin settings link fixed.

1.0.0 - 10/05/2018

  • Initial Release.

Frequently Asked Questions

Q. How could I import/export products costs from/to CSV file.

A. Exact steps depend on which tool you are using for importing/exporting the data:

  • If you are using the standard "WooCommerce products (CSV)" tool for importing products from CSV (as described here), then you just need to add to your CSV file column named:
    "Meta: _alg_wc_cog_cost"
  • If you are using some other tool for importing, then you need to set for the column to import to meta with _alg_wc_cog_cost key.
  • Similarly when exporting product costs, you would need to set to export product meta with _alg_wc_cog_cost key.

Q. After installing the plugin I still have nothing showing for profit etc.

A. Go to "WooCommerce > Settings > Cost of Goods", check "Recalculate orders cost and profit for all orders" option there and click "Save changes". This will calculate profit for all previous orders.

Free version

This plugin is a premium version of free "Cost of Goods for WooCommerce" plugin.

Developers

Product costs are stored in product's meta with _alg_wc_cog_cost key, so if you need to get it with PHP:

$product_cost = get_post_meta( $product_id, '_alg_wc_cog_cost', true );

As for the orders, profit and cost are stored in _alg_wc_cog_order_profit and _alg_wc_cog_order_cost meta respectively:

$order_profit = get_post_meta( $order_id, '_alg_wc_cog_order_profit', true );
$order_cost   = get_post_meta( $order_id, '_alg_wc_cog_order_cost',   true );

Prices & Licenses

Single siteUnlimited sites
1 year[buy] $29.99 / year[buy] $79.99 / year
Lifetime[buy] $49.99[buy] $149.99

Installation and Updates

  • Buy the plugin 🙂
  • Download plugin's zip to your computer (you will receive an email with download link, or you can always download the plugin from your account).
  • Go to "Admin Dashboard > Plugins > Add New > Upload Plugin" and browse for downloaded zip file.
  • If plugin is successfully installed - you should see it added to the Plugins list.
  • To keep WPFactory items up to date, please install WPFactory Helper plugin and enter your site key.

Refunds

We want to ensure that you are 100% happy with your purchase, so if you feel the product(s) you purchased are not the best fit for your requirements and you attempted to resolve issues with product's author, we are offering 30 day money back guarantee refund policy.