<?xml version="1.0" encoding="UTF-8"?>

<!--XBRL Document Created with the Workiva Platform-->
<!--Copyright 2026 Workiva-->
<!--r:019dd584-5f91-7e5b-9815-7cd5543c28ea,g:73528be9-7b72-4999-ba52-5847ee0f4ab6-->
<link:linkbase xmlns:link="http://www.xbrl.org/2003/linkbase" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.xbrl.org/2003/linkbase http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd">
  <link:arcroleRef arcroleURI="https://xbrl.org/2023/arcrole/summation-item" xlink:type="simple" xlink:href="https://www.xbrl.org/2023/calculation-1.1.xsd#summation-item"/>
  <link:roleRef roleURI="http://www.cognex.com/role/ConsolidatedStatementsofOperations" xlink:type="simple" xlink:href="cgnx-20260405.xsd#ConsolidatedStatementsofOperations"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/ConsolidatedStatementsofOperations" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GrossProfit_019dd584-605f-7a70-98b4-e36a9478c5d2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GrossProfit"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_019dd584-605f-7c81-bc1f-bfea46e28482" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_GrossProfit_019dd584-605f-7a70-98b4-e36a9478c5d2" xlink:to="loc_us-gaap_RevenueFromContractWithCustomerExcludingAssessedTax_019dd584-605f-7c81-bc1f-bfea46e28482" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CostOfGoodsAndServicesSold_019dd584-605f-77ca-87ca-7e9365fb0dcf" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CostOfGoodsAndServicesSold"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_GrossProfit_019dd584-605f-7a70-98b4-e36a9478c5d2" xlink:to="loc_us-gaap_CostOfGoodsAndServicesSold_019dd584-605f-77ca-87ca-7e9365fb0dcf" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingIncomeLoss_019dd584-605f-7e76-91b4-f4453b9bb1c7" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OperatingIncomeLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GrossProfit_019dd584-605f-781e-b1f2-533daec4461b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GrossProfit"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingIncomeLoss_019dd584-605f-7e76-91b4-f4453b9bb1c7" xlink:to="loc_us-gaap_GrossProfit_019dd584-605f-781e-b1f2-533daec4461b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpense_019dd584-605f-7410-9f2e-eaa88dda1d67" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_SellingGeneralAndAdministrativeExpense"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingIncomeLoss_019dd584-605f-7e76-91b4-f4453b9bb1c7" xlink:to="loc_us-gaap_SellingGeneralAndAdministrativeExpense_019dd584-605f-7410-9f2e-eaa88dda1d67" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ResearchAndDevelopmentExpense_019dd584-605f-78d7-ac47-4a7c668eae79" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ResearchAndDevelopmentExpense"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OperatingIncomeLoss_019dd584-605f-7e76-91b4-f4453b9bb1c7" xlink:to="loc_us-gaap_ResearchAndDevelopmentExpense_019dd584-605f-78d7-ac47-4a7c668eae79" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_019dd584-605f-7b33-8138-e9e646a9f312" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019dd584-605f-78b6-bea5-104accb9557d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_019dd584-605f-7b33-8138-e9e646a9f312" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019dd584-605f-78b6-bea5-104accb9557d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_019dd584-605f-7669-af90-9678e4933a61" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncomeTaxExpenseBenefit"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_019dd584-605f-7b33-8138-e9e646a9f312" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_019dd584-605f-7669-af90-9678e4933a61" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019dd584-605f-72db-831a-590626d2f31c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingIncomeLoss_019dd584-605f-7be0-a7fd-1946b62ef88d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OperatingIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019dd584-605f-72db-831a-590626d2f31c" xlink:to="loc_us-gaap_OperatingIncomeLoss_019dd584-605f-7be0-a7fd-1946b62ef88d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ForeignCurrencyTransactionGainLossBeforeTax_019dd584-605f-7b1e-b2e7-76050fb6e865" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ForeignCurrencyTransactionGainLossBeforeTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019dd584-605f-72db-831a-590626d2f31c" xlink:to="loc_us-gaap_ForeignCurrencyTransactionGainLossBeforeTax_019dd584-605f-7b1e-b2e7-76050fb6e865" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InvestmentIncomeNonoperating_019dd584-605f-7ded-9984-119f26f5bb56" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InvestmentIncomeNonoperating"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019dd584-605f-72db-831a-590626d2f31c" xlink:to="loc_us-gaap_InvestmentIncomeNonoperating_019dd584-605f-7ded-9984-119f26f5bb56" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherNonoperatingIncomeExpense_019dd584-605f-7b12-9f22-cf2db5c17ccb" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherNonoperatingIncomeExpense"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019dd584-605f-72db-831a-590626d2f31c" xlink:to="loc_us-gaap_OtherNonoperatingIncomeExpense_019dd584-605f-7b12-9f22-cf2db5c17ccb" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/ConsolidatedStatementsofComprehensiveIncomeLoss" xlink:type="simple" xlink:href="cgnx-20260405.xsd#ConsolidatedStatementsofComprehensiveIncomeLoss"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/ConsolidatedStatementsofComprehensiveIncomeLoss" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ComprehensiveIncomeNetOfTax_019dd584-605f-7d9e-ad1e-0139030063a9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ComprehensiveIncomeNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_019dd584-605f-7214-8727-12a501e64923" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTax_019dd584-605f-7d9e-ad1e-0139030063a9" xlink:to="loc_us-gaap_NetIncomeLoss_019dd584-605f-7214-8727-12a501e64923" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019dd584-605f-792b-8122-f41ff3c5e5a9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTax_019dd584-605f-7d9e-ad1e-0139030063a9" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019dd584-605f-792b-8122-f41ff3c5e5a9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019dd584-605f-7565-91b1-c8bfb1250423" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToParent_019dd584-605f-7bae-a6c5-dbce785ff40f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToParent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019dd584-605f-7565-91b1-c8bfb1250423" xlink:to="loc_us-gaap_OtherComprehensiveIncomeForeignCurrencyTransactionAndTranslationAdjustmentNetOfTaxPortionAttributableToParent_019dd584-605f-7bae-a6c5-dbce785ff40f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeAvailableforsaleSecuritiesAdjustmentNetOfTaxPortionAttributableToParent_019dd584-605f-71f9-a45a-d0d5d7ce2969" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeAvailableforsaleSecuritiesAdjustmentNetOfTaxPortionAttributableToParent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019dd584-605f-7565-91b1-c8bfb1250423" xlink:to="loc_us-gaap_OtherComprehensiveIncomeAvailableforsaleSecuritiesAdjustmentNetOfTaxPortionAttributableToParent_019dd584-605f-71f9-a45a-d0d5d7ce2969" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeAvailableforsaleSecuritiesAdjustmentNetOfTaxPortionAttributableToParent_019dd584-605f-777c-b83b-d276a90e3d64" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeAvailableforsaleSecuritiesAdjustmentNetOfTaxPortionAttributableToParent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeUnrealizedHoldingGainLossOnSecuritiesArisingDuringPeriodNetOfTax_019dd584-605f-7659-9abc-9a34cddc562c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeUnrealizedHoldingGainLossOnSecuritiesArisingDuringPeriodNetOfTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeAvailableforsaleSecuritiesAdjustmentNetOfTaxPortionAttributableToParent_019dd584-605f-777c-b83b-d276a90e3d64" xlink:to="loc_us-gaap_OtherComprehensiveIncomeUnrealizedHoldingGainLossOnSecuritiesArisingDuringPeriodNetOfTax_019dd584-605f-7659-9abc-9a34cddc562c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIForSaleOfSecuritiesNetOfTax_019dd584-605f-7184-8a00-e5b4799a0ff5" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIForSaleOfSecuritiesNetOfTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeAvailableforsaleSecuritiesAdjustmentNetOfTaxPortionAttributableToParent_019dd584-605f-777c-b83b-d276a90e3d64" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossReclassificationAdjustmentFromAOCIForSaleOfSecuritiesNetOfTax_019dd584-605f-7184-8a00-e5b4799a0ff5" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/ConsolidatedBalanceSheets" xlink:type="simple" xlink:href="cgnx-20260405.xsd#ConsolidatedBalanceSheets"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/ConsolidatedBalanceSheets" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsCurrent_019dd584-6118-7c0a-9819-dccbacd0c3dd" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AssetsCurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_019dd584-6118-7c5d-b56c-85ce514eb80b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CashAndCashEquivalentsAtCarryingValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_019dd584-6118-7c0a-9819-dccbacd0c3dd" xlink:to="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_019dd584-6118-7c5d-b56c-85ce514eb80b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtSecuritiesCurrent_019dd584-6118-7ca9-9278-f1d35de6d721" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtSecuritiesCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_019dd584-6118-7c0a-9819-dccbacd0c3dd" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtSecuritiesCurrent_019dd584-6118-7ca9-9278-f1d35de6d721" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsReceivableNetCurrent_019dd584-6118-7e3e-9568-6b9b9cad37db" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AccountsReceivableNetCurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_019dd584-6118-7c0a-9819-dccbacd0c3dd" xlink:to="loc_us-gaap_AccountsReceivableNetCurrent_019dd584-6118-7e3e-9568-6b9b9cad37db" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_UnbilledReceivablesCurrent_019dd584-6118-775a-aa78-f48d3dc175b0" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_UnbilledReceivablesCurrent"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_019dd584-6118-7c0a-9819-dccbacd0c3dd" xlink:to="loc_us-gaap_UnbilledReceivablesCurrent_019dd584-6118-775a-aa78-f48d3dc175b0" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryNet_019dd584-6118-7f09-8c7a-508650bcd217" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InventoryNet"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_019dd584-6118-7c0a-9819-dccbacd0c3dd" xlink:to="loc_us-gaap_InventoryNet_019dd584-6118-7f09-8c7a-508650bcd217" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_019dd584-6118-787a-a474-a1e3d5c1df21" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PrepaidExpenseAndOtherAssetsCurrent"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsCurrent_019dd584-6118-7c0a-9819-dccbacd0c3dd" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssetsCurrent_019dd584-6118-787a-a474-a1e3d5c1df21" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesCurrent_019dd584-605f-7c6b-aa67-79e86634735b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LiabilitiesCurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsPayableCurrent_019dd584-605f-73b1-a8a7-b6882199b22d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AccountsPayableCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_019dd584-605f-7c6b-aa67-79e86634735b" xlink:to="loc_us-gaap_AccountsPayableCurrent_019dd584-605f-73b1-a8a7-b6882199b22d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedLiabilitiesCurrent_019dd584-605f-7a0b-a30f-b0da86b4d7f0" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AccruedLiabilitiesCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_019dd584-605f-7c6b-aa67-79e86634735b" xlink:to="loc_us-gaap_AccruedLiabilitiesCurrent_019dd584-605f-7a0b-a30f-b0da86b4d7f0" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccruedIncomeTaxesCurrent_019dd584-605f-7313-929c-beacf3aea9f2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AccruedIncomeTaxesCurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_019dd584-605f-7c6b-aa67-79e86634735b" xlink:to="loc_us-gaap_AccruedIncomeTaxesCurrent_019dd584-605f-7313-929c-beacf3aea9f2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ContractWithCustomerLiabilityCurrent_019dd584-605f-7971-83d5-b9926ac3e8e0" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ContractWithCustomerLiabilityCurrent"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_019dd584-605f-7c6b-aa67-79e86634735b" xlink:to="loc_us-gaap_ContractWithCustomerLiabilityCurrent_019dd584-605f-7971-83d5-b9926ac3e8e0" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiabilityCurrent_019dd584-605f-7ec0-baf4-b28edf36d45e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OperatingLeaseLiabilityCurrent"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesCurrent_019dd584-605f-7c6b-aa67-79e86634735b" xlink:to="loc_us-gaap_OperatingLeaseLiabilityCurrent_019dd584-605f-7ec0-baf4-b28edf36d45e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_019dd584-605f-722a-9d7b-cee8ca579fca" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Liabilities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesCurrent_019dd584-605f-7194-bd52-37c27bc520cb" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LiabilitiesCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019dd584-605f-722a-9d7b-cee8ca579fca" xlink:to="loc_us-gaap_LiabilitiesCurrent_019dd584-605f-7194-bd52-37c27bc520cb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_019dd584-605f-700a-8fc8-baaf77f9b120" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OperatingLeaseLiabilityNoncurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019dd584-605f-722a-9d7b-cee8ca579fca" xlink:to="loc_us-gaap_OperatingLeaseLiabilityNoncurrent_019dd584-605f-700a-8fc8-baaf77f9b120" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxLiabilitiesNet_019dd584-605f-7540-b8f0-19ff22e65d11" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DeferredIncomeTaxLiabilitiesNet"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019dd584-605f-722a-9d7b-cee8ca579fca" xlink:to="loc_us-gaap_DeferredIncomeTaxLiabilitiesNet_019dd584-605f-7540-b8f0-19ff22e65d11" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilityForUncertainTaxPositionsNoncurrent_019dd584-605f-78bf-925a-4ef54beec115" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LiabilityForUncertainTaxPositionsNoncurrent"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019dd584-605f-722a-9d7b-cee8ca579fca" xlink:to="loc_us-gaap_LiabilityForUncertainTaxPositionsNoncurrent_019dd584-605f-78bf-925a-4ef54beec115" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherLiabilitiesNoncurrent_019dd584-605f-79ff-aa58-117916ff902b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherLiabilitiesNoncurrent"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019dd584-605f-722a-9d7b-cee8ca579fca" xlink:to="loc_us-gaap_OtherLiabilitiesNoncurrent_019dd584-605f-79ff-aa58-117916ff902b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Assets"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsCurrent_019dd584-605f-7c2f-abfd-a75118d61cd8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AssetsCurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:to="loc_us-gaap_AssetsCurrent_019dd584-605f-7c2f-abfd-a75118d61cd8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermInvestments_019dd584-605f-7bcf-bd51-4a041709c683" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermInvestments"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:to="loc_us-gaap_LongTermInvestments_019dd584-605f-7bcf-bd51-4a041709c683" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PropertyPlantAndEquipmentNet_019dd584-605f-74d8-92a9-9e5ad6aaddba" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PropertyPlantAndEquipmentNet"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:to="loc_us-gaap_PropertyPlantAndEquipmentNet_019dd584-605f-74d8-92a9-9e5ad6aaddba" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseRightOfUseAsset_019dd584-6118-7dac-9173-18a72aa61342" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OperatingLeaseRightOfUseAsset"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:to="loc_us-gaap_OperatingLeaseRightOfUseAsset_019dd584-6118-7dac-9173-18a72aa61342" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Goodwill_019dd584-6118-7117-9eb8-13de255b9063" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Goodwill"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:to="loc_us-gaap_Goodwill_019dd584-6118-7117-9eb8-13de255b9063" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6118-787d-a3e9-d77e4086ed99" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsNet"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6118-787d-a3e9-d77e4086ed99" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxAssetsNet_019dd584-6118-765c-8444-9a15b5831376" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DeferredIncomeTaxAssetsNet"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:to="loc_us-gaap_DeferredIncomeTaxAssetsNet_019dd584-6118-765c-8444-9a15b5831376" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAssetsNoncurrent_019dd584-6118-795e-aa99-717ad27bc081" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherAssetsNoncurrent"/>
    <link:calculationArc order="8" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019dd584-605f-7e4d-93c0-9d7af9cc250b" xlink:to="loc_us-gaap_OtherAssetsNoncurrent_019dd584-6118-795e-aa99-717ad27bc081" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquity_019dd584-605f-7519-b3fc-245a85e5b3ba" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LiabilitiesAndStockholdersEquity"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_019dd584-605f-7ad5-b949-c58106edd99f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Liabilities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_019dd584-605f-7519-b3fc-245a85e5b3ba" xlink:to="loc_us-gaap_Liabilities_019dd584-605f-7ad5-b949-c58106edd99f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommitmentsAndContingencies_019dd584-605f-70cf-915d-9c6ed51abd5d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CommitmentsAndContingencies"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_019dd584-605f-7519-b3fc-245a85e5b3ba" xlink:to="loc_us-gaap_CommitmentsAndContingencies_019dd584-605f-70cf-915d-9c6ed51abd5d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquity_019dd584-605f-7075-8a67-d578a83e96c2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_StockholdersEquity"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_019dd584-605f-7519-b3fc-245a85e5b3ba" xlink:to="loc_us-gaap_StockholdersEquity_019dd584-605f-7075-8a67-d578a83e96c2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquity_019dd584-605f-7c03-84ec-6a553a5e50db" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_StockholdersEquity"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AdditionalPaidInCapitalCommonStock_019dd584-605f-706b-b44d-471e00472e3f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AdditionalPaidInCapitalCommonStock"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019dd584-605f-7c03-84ec-6a553a5e50db" xlink:to="loc_us-gaap_AdditionalPaidInCapitalCommonStock_019dd584-605f-706b-b44d-471e00472e3f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RetainedEarningsAccumulatedDeficit_019dd584-605f-7760-81e9-d52d0177a8f1" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_RetainedEarningsAccumulatedDeficit"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019dd584-605f-7c03-84ec-6a553a5e50db" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_019dd584-605f-7760-81e9-d52d0177a8f1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_019dd584-605f-76d2-9fef-68f6a91914d7" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019dd584-605f-7c03-84ec-6a553a5e50db" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_019dd584-605f-76d2-9fef-68f6a91914d7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PreferredStockValueOutstanding_019dd584-605f-787d-842d-f4f878e5a6b7" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PreferredStockValueOutstanding"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019dd584-605f-7c03-84ec-6a553a5e50db" xlink:to="loc_us-gaap_PreferredStockValueOutstanding_019dd584-605f-787d-842d-f4f878e5a6b7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommonStockValueOutstanding_019dd584-605f-7cbe-a82c-94e72720d38a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CommonStockValueOutstanding"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019dd584-605f-7c03-84ec-6a553a5e50db" xlink:to="loc_us-gaap_CommonStockValueOutstanding_019dd584-605f-7cbe-a82c-94e72720d38a" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/ConsolidatedStatementsofCashFlows" xlink:type="simple" xlink:href="cgnx-20260405.xsd#ConsolidatedStatementsofCashFlows"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/ConsolidatedStatementsofCashFlows" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_019dd584-6118-7015-baaa-34d52a94cb22" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_NetIncomeLoss_019dd584-6118-7015-baaa-34d52a94cb22" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockOptionPlanExpense_019dd584-6118-7320-b845-11da8086cd70" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_StockOptionPlanExpense"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_StockOptionPlanExpense_019dd584-6118-7320-b845-11da8086cd70" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Depreciation_019dd584-6118-7dd3-b859-1cdac7eb3155" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Depreciation"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_Depreciation_019dd584-6118-7dd3-b859-1cdac7eb3155" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AmortizationOfIntangibleAssets_019dd584-6118-70af-b81a-96f28c6fbdd7" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AmortizationOfIntangibleAssets"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_AmortizationOfIntangibleAssets_019dd584-6118-70af-b81a-96f28c6fbdd7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_ExcessAndObsoleteInventoryCharges_019dd584-6118-708c-bba8-a98fef425927" xlink:href="cgnx-20260405.xsd#cgnx_ExcessAndObsoleteInventoryCharges"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_cgnx_ExcessAndObsoleteInventoryCharges_019dd584-6118-708c-bba8-a98fef425927" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInDeferredIncomeTaxes_019dd584-6118-785d-a408-5de776e5bad2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInDeferredIncomeTaxes"/>
    <link:calculationArc order="6" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInDeferredIncomeTaxes_019dd584-6118-785d-a408-5de776e5bad2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccountsReceivable_019dd584-6118-771c-aa0a-e0359b946dc5" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInAccountsReceivable"/>
    <link:calculationArc order="7" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsReceivable_019dd584-6118-771c-aa0a-e0359b946dc5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInContractWithCustomerLiability_019dd584-6118-764d-aeb2-909f261099ba" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInContractWithCustomerLiability"/>
    <link:calculationArc order="8" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInContractWithCustomerLiability_019dd584-6118-764d-aeb2-909f261099ba" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInInventories_019dd584-6118-7b73-8d11-c4d5391b6288" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInInventories"/>
    <link:calculationArc order="9" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInInventories_019dd584-6118-7b73-8d11-c4d5391b6288" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_019dd584-6118-7f57-99f4-2b5fa3565732" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets"/>
    <link:calculationArc order="10" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInPrepaidDeferredExpenseAndOtherAssets_019dd584-6118-7f57-99f4-2b5fa3565732" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccountsPayable_019dd584-6118-7e42-9fd1-cd4f4e072074" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInAccountsPayable"/>
    <link:calculationArc order="11" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInAccountsPayable_019dd584-6118-7e42-9fd1-cd4f4e072074" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccruedLiabilities_019dd584-6118-700e-b956-729d67bd022b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInAccruedLiabilities"/>
    <link:calculationArc order="12" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInAccruedLiabilities_019dd584-6118-700e-b956-729d67bd022b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccruedTaxesPayable_019dd584-6118-7449-98dd-90c868c25df4" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInAccruedTaxesPayable"/>
    <link:calculationArc order="13" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInAccruedTaxesPayable_019dd584-6118-7449-98dd-90c868c25df4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInDeferredRevenue_019dd584-6118-7768-b254-7753afc79e32" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInDeferredRevenue"/>
    <link:calculationArc order="14" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInDeferredRevenue_019dd584-6118-7768-b254-7753afc79e32" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInOtherOperatingCapitalNet_019dd584-6118-7be1-bb10-3e9089938a33" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInOtherOperatingCapitalNet"/>
    <link:calculationArc order="15" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_IncreaseDecreaseInOtherOperatingCapitalNet_019dd584-6118-7be1-bb10-3e9089938a33" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsForOtherOperatingActivities_019ddefc-8af9-7590-8ad7-b5ed628bfe00" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsForOtherOperatingActivities"/>
    <link:calculationArc order="16" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_PaymentsForOtherOperatingActivities_019ddefc-8af9-7590-8ad7-b5ed628bfe00" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GainLossOnSaleOfBusiness_019ddefe-087b-7fc6-96cc-6e9fe12e4f11" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GainLossOnSaleOfBusiness"/>
    <link:calculationArc order="17" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-702e-9ba1-f0064a71e173" xlink:to="loc_us-gaap_GainLossOnSaleOfBusiness_019ddefe-087b-7fc6-96cc-6e9fe12e4f11" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019dd584-6118-7bda-871c-a6f21cd00344" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_ProceedsPaymentsIssuanceOfSharesShareBasedPaymentArrangementIncludingOptionExercisedNet_019dd584-6118-71f3-bb7b-7900f632155e" xlink:href="cgnx-20260405.xsd#cgnx_ProceedsPaymentsIssuanceOfSharesShareBasedPaymentArrangementIncludingOptionExercisedNet"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019dd584-6118-7bda-871c-a6f21cd00344" xlink:to="loc_cgnx_ProceedsPaymentsIssuanceOfSharesShareBasedPaymentArrangementIncludingOptionExercisedNet_019dd584-6118-71f3-bb7b-7900f632155e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsForRepurchaseOfCommonStock_019dd584-6118-7913-8864-5ca9a6f2c35c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsForRepurchaseOfCommonStock"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019dd584-6118-7bda-871c-a6f21cd00344" xlink:to="loc_us-gaap_PaymentsForRepurchaseOfCommonStock_019dd584-6118-7913-8864-5ca9a6f2c35c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsOfDividendsCommonStock_019dd584-6118-70a2-8c34-9d3848ca01f1" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsOfDividendsCommonStock"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019dd584-6118-7bda-871c-a6f21cd00344" xlink:to="loc_us-gaap_PaymentsOfDividendsCommonStock_019dd584-6118-70a2-8c34-9d3848ca01f1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019dd584-6118-7ca8-b3fb-3e0cadc9b810" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-727c-b33f-f202866446ad" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019dd584-6118-7ca8-b3fb-3e0cadc9b810" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019dd584-6118-727c-b33f-f202866446ad" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019dd584-6118-70d0-8818-75305e631cc5" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019dd584-6118-7ca8-b3fb-3e0cadc9b810" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019dd584-6118-70d0-8818-75305e631cc5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019dd584-6118-7e74-8697-ab3ab6450aea" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019dd584-6118-7ca8-b3fb-3e0cadc9b810" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019dd584-6118-7e74-8697-ab3ab6450aea" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_019dd584-6118-78bb-bd2c-3537e6ef19a5" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019dd584-6118-7ca8-b3fb-3e0cadc9b810" xlink:to="loc_us-gaap_EffectOfExchangeRateOnCashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_019dd584-6118-78bb-bd2c-3537e6ef19a5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019dd584-6118-7a33-8962-6d6ff9e8d642" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireInvestments_019dd584-6118-7e81-aac1-10722f884327" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsToAcquireInvestments"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019dd584-6118-7a33-8962-6d6ff9e8d642" xlink:to="loc_us-gaap_PaymentsToAcquireInvestments_019dd584-6118-7e81-aac1-10722f884327" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromSaleMaturityAndCollectionsOfInvestments_019dd584-6118-7190-b515-cf7098eae418" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromSaleMaturityAndCollectionsOfInvestments"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019dd584-6118-7a33-8962-6d6ff9e8d642" xlink:to="loc_us-gaap_ProceedsFromSaleMaturityAndCollectionsOfInvestments_019dd584-6118-7190-b515-cf7098eae418" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromDivestitureOfBusinesses_019dd584-6118-7923-8cca-394a24babb2c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromDivestitureOfBusinesses"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019dd584-6118-7a33-8962-6d6ff9e8d642" xlink:to="loc_us-gaap_ProceedsFromDivestitureOfBusinesses_019dd584-6118-7923-8cca-394a24babb2c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquirePropertyPlantAndEquipment_019dd584-6118-756d-876e-a4ddb36da346" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsToAcquirePropertyPlantAndEquipment"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019dd584-6118-7a33-8962-6d6ff9e8d642" xlink:to="loc_us-gaap_PaymentsToAcquirePropertyPlantAndEquipment_019dd584-6118-756d-876e-a4ddb36da346" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/FinancialInstrumentsComponentsofCashCashEquivalentsandInvestmentsDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#FinancialInstrumentsComponentsofCashCashEquivalentsandInvestmentsDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/FinancialInstrumentsComponentsofCashCashEquivalentsandInvestmentsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_CashCashEquivalentsShortTermAndLongTermInvestmentsFairValue_019dd584-6118-79bf-a1ef-f0c3ce785e2f" xlink:href="cgnx-20260405.xsd#cgnx_CashCashEquivalentsShortTermAndLongTermInvestmentsFairValue"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6118-7824-9c94-182d841d77c6" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtSecurities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_cgnx_CashCashEquivalentsShortTermAndLongTermInvestmentsFairValue_019dd584-6118-79bf-a1ef-f0c3ce785e2f" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6118-7824-9c94-182d841d77c6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashAndCashEquivalentsFairValueDisclosure_019dd584-6118-78e8-a90b-159082f19ee7" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CashAndCashEquivalentsFairValueDisclosure"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_cgnx_CashCashEquivalentsShortTermAndLongTermInvestmentsFairValue_019dd584-6118-79bf-a1ef-f0c3ce785e2f" xlink:to="loc_us-gaap_CashAndCashEquivalentsFairValueDisclosure_019dd584-6118-78e8-a90b-159082f19ee7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6118-746b-a855-8277a54998b2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtSecurities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleDebtSecuritiesAmortizedCostBasis_019dd584-6118-7a1c-b8ba-f9e9ae99c61c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleDebtSecuritiesAmortizedCostBasis"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6118-746b-a855-8277a54998b2" xlink:to="loc_us-gaap_AvailableForSaleDebtSecuritiesAmortizedCostBasis_019dd584-6118-7a1c-b8ba-f9e9ae99c61c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleDebtSecuritiesAccumulatedGrossUnrealizedGainBeforeTax_019dd584-6118-77dc-b2bd-ffac5fa864b6" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleDebtSecuritiesAccumulatedGrossUnrealizedGainBeforeTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6118-746b-a855-8277a54998b2" xlink:to="loc_us-gaap_AvailableForSaleDebtSecuritiesAccumulatedGrossUnrealizedGainBeforeTax_019dd584-6118-77dc-b2bd-ffac5fa864b6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleDebtSecuritiesAccumulatedGrossUnrealizedLossBeforeTax_019dd584-6118-7168-a8d0-73dbc99162f4" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleDebtSecuritiesAccumulatedGrossUnrealizedLossBeforeTax"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6118-746b-a855-8277a54998b2" xlink:to="loc_us-gaap_AvailableForSaleDebtSecuritiesAccumulatedGrossUnrealizedLossBeforeTax_019dd584-6118-7168-a8d0-73dbc99162f4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_CashCashEquivalentsShortTermAndLongTermInvestments_019dd584-6118-71a0-a20f-63f31c88f356" xlink:href="cgnx-20260405.xsd#cgnx_CashCashEquivalentsShortTermAndLongTermInvestments"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_019dd584-6118-7987-9e8c-d609a41f97dd" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CashAndCashEquivalentsAtCarryingValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_cgnx_CashCashEquivalentsShortTermAndLongTermInvestments_019dd584-6118-71a0-a20f-63f31c88f356" xlink:to="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_019dd584-6118-7987-9e8c-d609a41f97dd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleDebtSecuritiesAmortizedCostBasis_019dd584-6118-784a-9e12-5473a231f2cb" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleDebtSecuritiesAmortizedCostBasis"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_cgnx_CashCashEquivalentsShortTermAndLongTermInvestments_019dd584-6118-71a0-a20f-63f31c88f356" xlink:to="loc_us-gaap_AvailableForSaleDebtSecuritiesAmortizedCostBasis_019dd584-6118-784a-9e12-5473a231f2cb" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/FinancialInstrumentsGrossUnrealizedLossesandFairValuesforAvailableforSaleInvestmentsDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#FinancialInstrumentsGrossUnrealizedLossesandFairValuesforAvailableforSaleInvestmentsDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/FinancialInstrumentsGrossUnrealizedLossesandFairValuesforAvailableforSaleInvestmentsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleUnrealizedLossPosition_019dd584-6118-7b3c-9b7a-3a1f7e796921" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleUnrealizedLossPosition"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPosition12MonthsOrLonger_019dd584-6118-7d64-834b-920263435f7c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPosition12MonthsOrLonger"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleUnrealizedLossPosition_019dd584-6118-7b3c-9b7a-3a1f7e796921" xlink:to="loc_us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPosition12MonthsOrLonger_019dd584-6118-7d64-834b-920263435f7c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPositionLessThan12Months_019dd584-6118-7b72-9924-59c38217df6a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPositionLessThan12Months"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleUnrealizedLossPosition_019dd584-6118-7b3c-9b7a-3a1f7e796921" xlink:to="loc_us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPositionLessThan12Months_019dd584-6118-7b72-9924-59c38217df6a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleUnrealizedLossPositionAccumulatedLoss_019dd584-6118-75e4-91dd-cc329b2029f0" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleUnrealizedLossPositionAccumulatedLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPositionLessThan12MonthsAccumulatedLoss_019dd584-6118-7696-8e7f-9c659c3ddcff" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPositionLessThan12MonthsAccumulatedLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleUnrealizedLossPositionAccumulatedLoss_019dd584-6118-75e4-91dd-cc329b2029f0" xlink:to="loc_us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPositionLessThan12MonthsAccumulatedLoss_019dd584-6118-7696-8e7f-9c659c3ddcff" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPosition12MonthsOrLongerAccumulatedLoss_019dd584-6118-7dde-8d2b-effeb1907857" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPosition12MonthsOrLongerAccumulatedLoss"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleUnrealizedLossPositionAccumulatedLoss_019dd584-6118-75e4-91dd-cc329b2029f0" xlink:to="loc_us-gaap_DebtSecuritiesAvailableForSaleContinuousUnrealizedLossPosition12MonthsOrLongerAccumulatedLoss_019dd584-6118-7dde-8d2b-effeb1907857" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/FinancialInstrumentsEffectiveMaturityDatesofAvailableforSaleInvestmentsDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#FinancialInstrumentsEffectiveMaturityDatesofAvailableforSaleInvestmentsDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/FinancialInstrumentsEffectiveMaturityDatesofAvailableforSaleInvestmentsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6119-7720-92d5-f392dd200d9c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtSecurities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue_019dd584-6119-7f75-88b7-a2b4ee9101e7" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6119-7720-92d5-f392dd200d9c" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue_019dd584-6119-7f75-88b7-a2b4ee9101e7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterOneYearBeforeTwoYearsFairValue_019dd584-6119-7bb1-9b13-ca7d02c07504" xlink:href="cgnx-20260405.xsd#cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterOneYearBeforeTwoYearsFairValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6119-7720-92d5-f392dd200d9c" xlink:to="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterOneYearBeforeTwoYearsFairValue_019dd584-6119-7bb1-9b13-ca7d02c07504" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterTwoYearsBeforeThreeYearsFairValue_019dd584-6119-7955-b5d7-62f5e6980a9c" xlink:href="cgnx-20260405.xsd#cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterTwoYearsBeforeThreeYearsFairValue"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6119-7720-92d5-f392dd200d9c" xlink:to="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterTwoYearsBeforeThreeYearsFairValue_019dd584-6119-7955-b5d7-62f5e6980a9c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterThreeYearsBeforeFourYearsFairValue_019dd584-6119-75f3-9a12-89dec334db4c" xlink:href="cgnx-20260405.xsd#cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterThreeYearsBeforeFourYearsFairValue"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6119-7720-92d5-f392dd200d9c" xlink:to="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterThreeYearsBeforeFourYearsFairValue_019dd584-6119-75f3-9a12-89dec334db4c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterFourYearsBeforeFiveYearsFairValue_019dd584-6119-780d-a5a1-819a8bc08e5e" xlink:href="cgnx-20260405.xsd#cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterFourYearsBeforeFiveYearsFairValue"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6119-7720-92d5-f392dd200d9c" xlink:to="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterFourYearsBeforeFiveYearsFairValue_019dd584-6119-780d-a5a1-819a8bc08e5e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveYearsBeforeEightYearsFairValue_019dd584-6119-71cd-9ae1-b250a759f011" xlink:href="cgnx-20260405.xsd#cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveYearsBeforeEightYearsFairValue"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AvailableForSaleSecuritiesDebtSecurities_019dd584-6119-7720-92d5-f392dd200d9c" xlink:to="loc_cgnx_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveYearsBeforeEightYearsFairValue_019dd584-6119-71cd-9ae1-b250a759f011" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/FinancialInstrumentsAssetsandliabilitiespresentedonanetbasisduetotherightofoffsetDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#FinancialInstrumentsAssetsandliabilitiespresentedonanetbasisduetotherightofoffsetDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/FinancialInstrumentsAssetsandliabilitiespresentedonanetbasisduetotherightofoffsetDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilities_019dd584-6119-780d-8480-ca37c3106929" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeLiabilities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_019dd584-6119-7d11-bbcf-6e88f46fdcbe" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeFairValueOfDerivativeLiability"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilities_019dd584-6119-780d-8480-ca37c3106929" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_019dd584-6119-7d11-bbcf-6e88f46fdcbe" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityCollateralRightToReclaimCashOffset_019dd584-6119-7512-81d2-15e42ee636ff" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeLiabilityCollateralRightToReclaimCashOffset"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilities_019dd584-6119-780d-8480-ca37c3106929" xlink:to="loc_us-gaap_DerivativeLiabilityCollateralRightToReclaimCashOffset_019dd584-6119-7512-81d2-15e42ee636ff" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssets_019dd584-6119-74d4-b621-3d8db9f7f8b6" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeAssets"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_019dd584-6119-7def-9793-873bb76cb176" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeFairValueOfDerivativeAsset"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssets_019dd584-6119-74d4-b621-3d8db9f7f8b6" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_019dd584-6119-7def-9793-873bb76cb176" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetCollateralObligationToReturnCashOffset_019dd584-6119-7a8a-8042-a5be71b0d710" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeAssetCollateralObligationToReturnCashOffset"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssets_019dd584-6119-74d4-b621-3d8db9f7f8b6" xlink:to="loc_us-gaap_DerivativeAssetCollateralObligationToReturnCashOffset_019dd584-6119-7a8a-8042-a5be71b0d710" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/InventoriesDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#InventoriesDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/InventoriesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryNet_019dd584-6119-7c49-b1ad-67746888b923" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InventoryNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryRawMaterialsNetOfReserves_019dd584-6119-7e8d-bd85-5d9601ecb45b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InventoryRawMaterialsNetOfReserves"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InventoryNet_019dd584-6119-7c49-b1ad-67746888b923" xlink:to="loc_us-gaap_InventoryRawMaterialsNetOfReserves_019dd584-6119-7e8d-bd85-5d9601ecb45b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryWorkInProcessNetOfReserves_019dd584-6119-796f-8f66-fe8ea4fdca6d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InventoryWorkInProcessNetOfReserves"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InventoryNet_019dd584-6119-7c49-b1ad-67746888b923" xlink:to="loc_us-gaap_InventoryWorkInProcessNetOfReserves_019dd584-6119-796f-8f66-fe8ea4fdca6d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InventoryFinishedGoodsNetOfReserves_019dd584-6119-7d54-ae1d-f86d684fa28a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InventoryFinishedGoodsNetOfReserves"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InventoryNet_019dd584-6119-7c49-b1ad-67746888b923" xlink:to="loc_us-gaap_InventoryFinishedGoodsNetOfReserves_019dd584-6119-7d54-ae1d-f86d684fa28a" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/LeasesFutureMinimumLeasePaymentObligationsUnderOperatingLeasesDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#LeasesFutureMinimumLeasePaymentObligationsUnderOperatingLeasesDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/LeasesFutureMinimumLeasePaymentObligationsUnderOperatingLeasesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-76a3-81ea-df2437f0733c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear_019dd584-6119-7200-abed-08a395d130a3" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-76a3-81ea-df2437f0733c" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsRemainderOfFiscalYear_019dd584-6119-7200-abed-08a395d130a3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths_019dd584-6119-7ebf-a89c-793ea1ee88bd" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-76a3-81ea-df2437f0733c" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueNextTwelveMonths_019dd584-6119-7ebf-a89c-793ea1ee88bd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo_019dd584-6119-7f6d-860e-1c0a6e7c3075" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-76a3-81ea-df2437f0733c" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearTwo_019dd584-6119-7f6d-860e-1c0a6e7c3075" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree_019dd584-6119-7a52-8c17-ec41babb2d25" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-76a3-81ea-df2437f0733c" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearThree_019dd584-6119-7a52-8c17-ec41babb2d25" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour_019dd584-6119-7f15-a0d9-9484fc8891bb" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-76a3-81ea-df2437f0733c" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFour_019dd584-6119-7f15-a0d9-9484fc8891bb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFive_019dd584-6119-743d-b6af-4ce3a61ff979" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFive"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-76a3-81ea-df2437f0733c" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueYearFive_019dd584-6119-743d-b6af-4ce3a61ff979" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueAfterYearFive_019dd584-6119-71b4-ac39-3671b4fe757d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueAfterYearFive"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-76a3-81ea-df2437f0733c" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDueAfterYearFive_019dd584-6119-71b4-ac39-3671b4fe757d" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/LeasesFutureMinimumLeasePaymentObligationsUnderOperatingLeasesDetails_1" xlink:type="simple" xlink:href="cgnx-20260405.xsd#LeasesFutureMinimumLeasePaymentObligationsUnderOperatingLeasesDetails_1"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/LeasesFutureMinimumLeasePaymentObligationsUnderOperatingLeasesDetails_1" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-7b19-a409-a3a2b90abb79" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OperatingLeaseLiability_019dd584-6119-7646-9682-50f008d57a2e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OperatingLeaseLiability"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-7b19-a409-a3a2b90abb79" xlink:to="loc_us-gaap_OperatingLeaseLiability_019dd584-6119-7646-9682-50f008d57a2e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LesseeOperatingLeaseLiabilityUndiscountedExcessAmount_019dd584-6119-7b24-a389-4ff490c3c46f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LesseeOperatingLeaseLiabilityUndiscountedExcessAmount"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LesseeOperatingLeaseLiabilityPaymentsDue_019dd584-6119-7b19-a409-a3a2b90abb79" xlink:to="loc_us-gaap_LesseeOperatingLeaseLiabilityUndiscountedExcessAmount_019dd584-6119-7b24-a389-4ff490c3c46f" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/GoodwillandIntangibleAssetsAmortizedAssetsandFutureAmortizationExpenseDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#GoodwillandIntangibleAssetsAmortizedAssetsandFutureAmortizationExpenseDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/GoodwillandIntangibleAssetsAmortizedAssetsandFutureAmortizationExpenseDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-7db2-83e3-4bbdf1847c8d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsGross_019dd584-6119-789e-886b-b07093c0d0e8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsGross"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-7db2-83e3-4bbdf1847c8d" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsGross_019dd584-6119-789e-886b-b07093c0d0e8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_019dd584-6119-77a7-afc6-7188ce6ace9b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-7db2-83e3-4bbdf1847c8d" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization_019dd584-6119-77a7-afc6-7188ce6ace9b" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/GoodwillandIntangibleAssetsAmortizedAssetsandFutureAmortizationExpenseDetails_1" xlink:type="simple" xlink:href="cgnx-20260405.xsd#GoodwillandIntangibleAssetsAmortizedAssetsandFutureAmortizationExpenseDetails_1"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/GoodwillandIntangibleAssetsAmortizedAssetsandFutureAmortizationExpenseDetails_1" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-79a1-9353-2d0b683f4700" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearFour_019dd584-6119-7604-addc-9e6b68897b85" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearFour"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-79a1-9353-2d0b683f4700" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearFour_019dd584-6119-7604-addc-9e6b68897b85" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseNextTwelveMonths_019dd584-6119-77a7-9bbb-b62088431904" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseNextTwelveMonths"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-79a1-9353-2d0b683f4700" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseNextTwelveMonths_019dd584-6119-77a7-9bbb-b62088431904" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearTwo_019dd584-6119-7f1d-9dab-75e6d918143b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearTwo"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-79a1-9353-2d0b683f4700" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearTwo_019dd584-6119-7f1d-9dab-75e6d918143b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearThree_019dd584-6119-79b3-beb0-a2ed2c559428" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearThree"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-79a1-9353-2d0b683f4700" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearThree_019dd584-6119-79b3-beb0-a2ed2c559428" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearFive_019dd584-6119-70dd-830d-80edd28ca6dd" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearFive"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-79a1-9353-2d0b683f4700" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseYearFive_019dd584-6119-70dd-830d-80edd28ca6dd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseRemainderOfFiscalYear_019dd584-6119-782f-b7a8-e882341a31fe" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseRemainderOfFiscalYear"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-79a1-9353-2d0b683f4700" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseRemainderOfFiscalYear_019dd584-6119-782f-b7a8-e882341a31fe" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseAfterYearFive_019dd584-6119-7464-8736-734c0308151b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseAfterYearFive"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FiniteLivedIntangibleAssetsNet_019dd584-6119-79a1-9353-2d0b683f4700" xlink:to="loc_us-gaap_FiniteLivedIntangibleAssetsAmortizationExpenseAfterYearFive_019dd584-6119-7464-8736-734c0308151b" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/EarningsperShareCalculationofWeightedAverageSharesDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#EarningsperShareCalculationofWeightedAverageSharesDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/EarningsperShareCalculationofWeightedAverageSharesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_019dd584-6119-7121-83f2-b878548600e9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_019dd584-6119-709f-bd70-46dcb8e4199d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_WeightedAverageNumberOfSharesOutstandingBasic"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_019dd584-6119-7121-83f2-b878548600e9" xlink:to="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_019dd584-6119-709f-bd70-46dcb8e4199d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_WeightedAverageNumberDilutedSharesOutstandingAdjustment_019dd584-6119-7c17-b850-45b9e2e52d1b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_WeightedAverageNumberDilutedSharesOutstandingAdjustment"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_019dd584-6119-7121-83f2-b878548600e9" xlink:to="loc_us-gaap_WeightedAverageNumberDilutedSharesOutstandingAdjustment_019dd584-6119-7c17-b850-45b9e2e52d1b" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/SegmentInformationDisaggregationofSegmentExpensesDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#SegmentInformationDisaggregationofSegmentExpensesDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/SegmentInformationDisaggregationofSegmentExpensesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SellingGeneralAndAdministrativeExpense_019dd584-6119-704b-b23b-985e62cc51f0" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_SellingGeneralAndAdministrativeExpense"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LaborAndRelatedExpense_019dd584-6119-7c9f-8c0c-f561964fd6c9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LaborAndRelatedExpense"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_SellingGeneralAndAdministrativeExpense_019dd584-6119-704b-b23b-985e62cc51f0" xlink:to="loc_us-gaap_LaborAndRelatedExpense_019dd584-6119-7c9f-8c0c-f561964fd6c9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherExpenses_019dd584-6119-7db1-9069-470521dfd785" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherExpenses"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_SellingGeneralAndAdministrativeExpense_019dd584-6119-704b-b23b-985e62cc51f0" xlink:to="loc_us-gaap_OtherExpenses_019dd584-6119-7db1-9069-470521dfd785" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AllocatedShareBasedCompensationExpense_019dd584-6119-75ab-b975-2226d3917c27" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AllocatedShareBasedCompensationExpense"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_SellingGeneralAndAdministrativeExpense_019dd584-6119-704b-b23b-985e62cc51f0" xlink:to="loc_us-gaap_AllocatedShareBasedCompensationExpense_019dd584-6119-75ab-b975-2226d3917c27" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_IncentiveCompensationExpenseBonusAndSalesCommissions_019dd584-6119-7cdb-aade-068b27823913" xlink:href="cgnx-20260405.xsd#cgnx_IncentiveCompensationExpenseBonusAndSalesCommissions"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_SellingGeneralAndAdministrativeExpense_019dd584-6119-704b-b23b-985e62cc51f0" xlink:to="loc_cgnx_IncentiveCompensationExpenseBonusAndSalesCommissions_019dd584-6119-7cdb-aade-068b27823913" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DepreciationDepletionAndAmortization_019dd584-6119-7f4b-9f2e-863aadf5cb4b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DepreciationDepletionAndAmortization"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_SellingGeneralAndAdministrativeExpense_019dd584-6119-704b-b23b-985e62cc51f0" xlink:to="loc_us-gaap_DepreciationDepletionAndAmortization_019dd584-6119-7f4b-9f2e-863aadf5cb4b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ResearchAndDevelopmentExpense_019dd584-6119-73b5-a69b-90eaeb6af34a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ResearchAndDevelopmentExpense"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherExpenses_019dd584-6119-79f3-ac9a-48b6276f5825" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherExpenses"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ResearchAndDevelopmentExpense_019dd584-6119-73b5-a69b-90eaeb6af34a" xlink:to="loc_us-gaap_OtherExpenses_019dd584-6119-79f3-ac9a-48b6276f5825" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_cgnx_IncentiveCompensationExpenseBonusAndSalesCommissions_019dd584-6119-7600-9325-496001002c09" xlink:href="cgnx-20260405.xsd#cgnx_IncentiveCompensationExpenseBonusAndSalesCommissions"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ResearchAndDevelopmentExpense_019dd584-6119-73b5-a69b-90eaeb6af34a" xlink:to="loc_cgnx_IncentiveCompensationExpenseBonusAndSalesCommissions_019dd584-6119-7600-9325-496001002c09" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AllocatedShareBasedCompensationExpense_019dd584-6119-74df-aabd-b71e78f19aa3" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AllocatedShareBasedCompensationExpense"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ResearchAndDevelopmentExpense_019dd584-6119-73b5-a69b-90eaeb6af34a" xlink:to="loc_us-gaap_AllocatedShareBasedCompensationExpense_019dd584-6119-74df-aabd-b71e78f19aa3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LaborAndRelatedExpense_019dd584-6119-7f28-8c7c-2fa69c3b499e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LaborAndRelatedExpense"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ResearchAndDevelopmentExpense_019dd584-6119-73b5-a69b-90eaeb6af34a" xlink:to="loc_us-gaap_LaborAndRelatedExpense_019dd584-6119-7f28-8c7c-2fa69c3b499e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DepreciationDepletionAndAmortization_019dd584-6119-7931-b700-8143b5fbc182" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DepreciationDepletionAndAmortization"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ResearchAndDevelopmentExpense_019dd584-6119-73b5-a69b-90eaeb6af34a" xlink:to="loc_us-gaap_DepreciationDepletionAndAmortization_019dd584-6119-7931-b700-8143b5fbc182" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.cognex.com/role/BusinessDisposalScheduleofMajorAssetsandLiabilitiesIncludedasPartofDisposalGroupDetails" xlink:type="simple" xlink:href="cgnx-20260405.xsd#BusinessDisposalScheduleofMajorAssetsandLiabilitiesIncludedasPartofDisposalGroupDetails"/>
  <link:calculationLink xlink:role="http://www.cognex.com/role/BusinessDisposalScheduleofMajorAssetsandLiabilitiesIncludedasPartofDisposalGroupDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation_019ddf31-cd89-79b6-86bc-e20588dad7d0" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationInventory1_019ddf31-cd89-7d66-88d7-5176f27d5e70" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationInventory1"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation_019ddf31-cd89-79b6-86bc-e20588dad7d0" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationInventory1_019ddf31-cd89-7d66-88d7-5176f27d5e70" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationGoodwill1_019ddf31-cd89-7f87-a8d1-ccb6b747dee6" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationGoodwill1"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation_019ddf31-cd89-79b6-86bc-e20588dad7d0" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationGoodwill1_019ddf31-cd89-7f87-a8d1-ccb6b747dee6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationIntangibleAssets_019ddf31-cd89-7575-b53f-23134bc15195" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationIntangibleAssets"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsOfDisposalGroupIncludingDiscontinuedOperation_019ddf31-cd89-79b6-86bc-e20588dad7d0" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationIntangibleAssets_019ddf31-cd89-7575-b53f-23134bc15195" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation_019ddf31-bf65-7a57-8c34-3a61eb2108a1" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationAccruedLiabilities_019ddf31-bf65-76b8-8553-b7508c89a845" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DisposalGroupIncludingDiscontinuedOperationAccruedLiabilities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesOfDisposalGroupIncludingDiscontinuedOperation_019ddf31-bf65-7a57-8c34-3a61eb2108a1" xlink:to="loc_us-gaap_DisposalGroupIncludingDiscontinuedOperationAccruedLiabilities_019ddf31-bf65-76b8-8553-b7508c89a845" xlink:type="arc"/>
  </link:calculationLink>
</link:linkbase>
